简体   繁体   中英

Windows Metro C++ C# - How to add namespace of WinRT Portable Project?

I am working on a Windows C++ Metro App, where I've added a separate portable project in C# to the solution.

When adding the namespace to the project the namespace is underlined in red, and hovering upon the namespace states: "Error: name must be a namespace name".

I am currently wondering how to resolve the namespace error.

You need to explicitly add the portable project as a reference in the C++ project. This will allow the namespace to be discovered properly, and should eliminate the error.

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