简体   繁体   中英

How can we add a NavigationViewItem in C++/WinRT in a WinUI3 desktop app?

I am having difficulty in finding an example of adding a NavigationViewItem in a WinRT/C++ WinUI3 desktop app. This question is answered for C# in the following Q&A .

But I cannot find the comparable answer for WinRT/C++. I understand that effectively I want to add the new NavigationViewItem to the NavigationView's MenuItems() list. It's just that I can't find the syntax to do that.

Microsoft published that in their github for C++/WinRT in a WinUI3 desktop.

  1. NavigationView winui c++/winrt

  2. microsoft / WindowsAppSDK-Samples

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM