Tutorials - Windows App SDK - Setup and ...

Tutorials - Windows App SDK - Setup and Start

Aug 29, 2022

Setup and Start

Windows App SDK allows you to create Applications by providing a modern Development Platform for Windows 11 and Windows 10 for version 1809 and later. You can get Setup in Windows 11, Install what you need with Visual Studio 2022 and get ready to Start creating Applications using Windows App SDK

Setup

You will need to enable Developer Mode in Windows 11 if this has not been enabled then you can do so with the following:

Right-Click on Start then select Settings or Search for Settings from the Start Menu and Select it.

Next from Settings select Privacy & security

Then in Privacy & security select For developers

Finally in For developers make sure that the Toggle underneath Install apps from any source, including loose files is set to On if it is not already.

Install

Windows App SDK Applications will be created using Visual Studio 2022 to Install this, if this has not be done already or to check you have what you need, you can do so with the following:

Visit visualstudio.com from your Browser, then from the Download Visual Studio section you can pick Community 2022 which is a version of Visual Studio 2022 that you can use for free to create your Applications with.

Next once the Download has completed from the Thank you for downloading Visual Studio screen choose the Open file option or similar in your Browser or find the VisualStudioSetup.exe in your Downloads and double-click on it.

 

Once the VisualStudioSetup.exe has started this will launch the Visual Studio Installer, select Continue to begin Installation.

Next select .NET desktop development from the Workloads section in the Visual Studio Installer.

Then from Installation details make sure that Windows App SDK C# Templates is selected and then select Install or Modify and follow any further instructions to complete the Installation of Visual Studio 2022 and Windows App SDK.

Start

To get Started with a Tutorial you will need to open Visual Studio 2022 and Create a new project, do this with the following:

In Windows 11 choose Start and then find or search for Visual Studio 2022 and then select it.

Once Visual Studio 2022 has started select Create a new project.

Then choose the Blank App, Packages (WinUI in Desktop) and then select Next.

After that in Configure your new project pick a Project name and Location and then select Create

Finally the Solution for your Application will be opened in Visual Studio 2022

Guide

Visual Studio has a Menu at the top of the Window, when you need to do something from the Menu this is where you need to do it and there is also a Search box to find commands if needed.

In Visual Studio, below the Menu is the Toolbar options include Debug which will Start your Application with the name of the Application along with other options including Save.

When your Application is Running, the Toolbar will change to include other options including Stop to finish Debugging and Close your Application.

When a Solution has been opened or created in Visual Studio to then Edit or Add any Code for the Main Window for your Application, from Solution Explorer select the arrow next to MainWindow.xaml to reveal MainWindow.xaml.cs then double-click on it to for the Code for the Main Window.

Then to Edit or Add any XAML for the Main Window for your Application in Visual Studio from Solution Explorer double-click on MainWindow.xaml for the XAML of Main Window.

If you need to Add anything else to your Application, in Visual Studio from Solution Explorer right-click on the Project which is displayed under the Solution and then select the Add then New Item… option.In Add New Item you could select Code File in Code for a Class such as Library.cs or a Blank Page in WinUI, and then select the Add to include this new item in your Application.

Enjoy this post?

Buy Tutorialr a coffee

More from Tutorialr