mainwindow.xml.cs

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
public partial class MainWindow : MetroWindow
{
    private readonly IRegionManager regionManager;
    public MainWindow(IRegionManager regionManager)
    {
        InitializeComponent();
        this.regionManager = regionManager;
    }
 
 
    private void Button_Click(object sender, RoutedEventArgs e)
    {
        regionManager.RequestNavigate("ContentRegion", nameof(DefaultView));
    }
 
    private void MetroWindow_Loaded(object sender, RoutedEventArgs e)
    {
        regionManager.RequestNavigate("ContentRegion", nameof(DefaultView));
    }
}

  

 app.xml.cs

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
public partial class App
{
    protected override Window CreateShell()
    {
        return Container.Resolve<MainWindow>();
    }
 
    protected override void RegisterTypes(IContainerRegistry containerRegistry)
    {
        containerRegistry.RegisterSingleton<AppDbContext>(sp =>
        {
            var options = new DbContextOptionsBuilder<AppDbContext>()
                .UseSqlServer("Server=127.0.0.1;Database=db1;User Id=sa;Password=123456;")
                .Options;
            return new AppDbContext(options);
        });
        containerRegistry.RegisterForNavigation<DefaultView>();
    }
}

  

posted @ 2025-01-12 16:00 zyip 阅读(5) 评论(0) 推荐(0) 编辑
摘要: FolderProfile.pubxml <Project> <PropertyGroup> <TargetFramework>net6.0-windows7.0</TargetFramework> <PublishSingleFile>true</PublishSingleFile> <Confi 阅读全文
posted @ 2025-01-12 16:00 zyip 阅读(5) 评论(0) 推荐(0) 编辑
摘要: const routerCfg = import.meta.glob("./router.ts",{eager:true,import:'default'}) console.log(routerCfg) 阅读全文
posted @ 2024-12-20 09:30 zyip 阅读(5) 评论(0) 推荐(0) 编辑
摘要: MySQL :: Download MySQL Installer (Archived Versions) MySQL :: MySQL Workbench JetBrains 2023最新全家桶激活教程,亲测有效!1 (kdocs.cn) 阅读全文
posted @ 2024-07-07 21:03 zyip 阅读(7) 评论(0) 推荐(0) 编辑
摘要: https://www.youtube.com/watch?v=32aGKBDEWMg&list=PLE_VuAjgd8mrzMr5DV-OHgtb15XzZNc18 download https://mega.nz/folder/WtFwWIZB#swLFgAQA156pSBNLYQNk2g 阅读全文
posted @ 2024-04-12 00:19 zyip 阅读(23) 评论(0) 推荐(0) 编辑
摘要: New Jupyter lab/notebook import asyncio import time async def my_coroutine(): await asyncio.sleep(1) print("Coroutine executed!") s = time.perf_counte 阅读全文
posted @ 2024-04-03 22:00 zyip 阅读(79) 评论(0) 推荐(0) 编辑
摘要: server1 using System; using System.Threading.Tasks; using System.Net; using System.Net.Sockets; using System.Threading; namespace Comm2 { public class 阅读全文
posted @ 2024-03-26 10:03 zyip 阅读(12) 评论(0) 推荐(0) 编辑
摘要: https://dortania.github.io/OpenCore-Install-Guide/macos-limits.html https://dortania.github.io/OpenCore-Legacy-Patcher/START.html#how-do-i-get-started 阅读全文
posted @ 2024-03-21 14:48 zyip 阅读(15) 评论(0) 推荐(0) 编辑
摘要: https://hexed.it/ 安装软件之后,使用 Sublime Text 打开安装目录下的 sublime_text.exe 文件。 搜索到 8078 0500 0f94 c1,更改为 c640 0501 4885 c9。 把文件另存到其他路径,然后关闭 Sublime Text,将原 su 阅读全文
posted @ 2024-03-19 20:35 zyip 阅读(101) 评论(0) 推荐(0) 编辑
摘要: pip install --upgrade pip pip install huggingface-cli git config --global credential.helper store huggingface-cli login huggingface-cli download adept 阅读全文
posted @ 2024-02-29 15:12 zyip 阅读(63) 评论(0) 推荐(0) 编辑
点击右上角即可分享
微信分享提示