Skip to content

Commit 9a3c5c1

Browse files
Merge pull request #6473 from MicrosoftDocs/fix/winui-getting-started-gaps
Fix WinUI getting-started gaps: template tip, packaged callout, DLL error FAQ
2 parents 0ee5adf + 2cf6cb8 commit 9a3c5c1

2 files changed

Lines changed: 18 additions & 0 deletions

File tree

hub/apps/get-started/start-here.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,9 @@ In the Visual Studio Installer, select the following workloads on the **Workload
5858

5959
* **For C++ app development**, select the **C++ WinUI app development tools** under the **WinUI application development** node in the **Installation details** pane (This will also select any additional required components.)
6060

61+
> [!TIP]
62+
> If you don't see WinUI templates after installing Visual Studio, open the Visual Studio Installer, select **Modify**, and confirm the **WinUI application development** workload is checked. Restart Visual Studio after modifying the installation.
63+
6164
---
6265

6366
## Create and launch your first WinUI app
@@ -66,6 +69,9 @@ In the Visual Studio Installer, select the following workloads on the **Workload
6669

6770
2. Search for **WinUI**, select the **WinUI Blank App (Packaged)** C# project template, and select **Next**.
6871

72+
> [!NOTE]
73+
> The **Packaged** template is recommended for new apps. A packaged app (using MSIX) gives your users a clean install and uninstall experience, and enables Windows features like notifications, background tasks, and the Microsoft Store. You can learn more about the packaged vs. unpackaged choice in [Windows apps: packaging, deployment, and process](intro-pack-dep-proc.md).
74+
6975
:::image type="content" source="images/hello-world/create-project.png" lightbox="images/hello-world/create-project.png" alt-text="Blank, packaged WinUI C# desktop app":::
7076

7177
3. Enter a project name and select **Create**.

hub/apps/get-started/windows-developer-faq.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,18 @@ Topics covered include:
103103
104104
</details>
105105

106+
<details><summary>I get an "Unable to load DLL 'Microsoft.ui.xaml.dll'" error when running my app. How do I fix it?</summary>
107+
108+
> This error usually occurs in **unpackaged** app scenarios where the Windows App SDK runtime hasn't been installed on the machine. Try the following:
109+
>
110+
> - If you're running a **packaged** app (the recommended default), ensure you're launching via Visual Studio with the **MsixPackage** launch profile selected (not the plain executable profile). The MSIX packaging step installs the required runtime components.
111+
> - If you're running an **unpackaged** app, you must install the [Windows App SDK runtime](../windows-app-sdk/downloads.md) separately before running the app outside of Visual Studio.
112+
> - If the error occurs during development, open your `.csproj` and confirm that your packaging configuration matches your deployment model: for **packaged** apps, omit the `<WindowsPackageType>` property (or leave it at its default) and build/run the MSIX package; for **unpackaged** apps, set `<WindowsPackageType>None</WindowsPackageType>` and ensure you've called `Bootstrap.Initialize()` at startup.
113+
>
114+
> See [Deploy apps that use the Windows App SDK](../package-and-deploy/deploy-overview.md) for more details on deployment requirements.
115+
116+
</details>
117+
106118
<details><summary>What is the difference between WinUI and WinUI for UWP?</summary>
107119

108120
> **WinUI** (previously referred to as WinUI 3) is the latest native UI framework for Windows app development. It provides a modern and flexible UI framework for creating visually appealing and interactive Windows apps. WinUI is part of the Windows App SDK and works best with the latest versions of Windows.

0 commit comments

Comments
 (0)