Closed robertsi closed 4 years ago
Hello robertsi, thank you for your interest in Win32!
I have automatically added a "needs triage" label to help get things started. Our team will look into the question and answer ASAP. Other community members may also answer the question and provide feedback 🙌
Well had to comment out #define WIN32_LEAN_AND_MEAN in framework.h. Should have been mentioned in "Host a standard UWP control in a C++ Win32 app"!!! Code there just happens to work because it deletes the framework.h include...
In general WinRT tooling in 16.5.3 is a headache atm, especially with the usercontrol, viewmodel grouping bug (https://developercommunity.visualstudio.com/content/problem/959456/item-template-dependent-nesting-behavior-broken-in.html) ...almost unusable unless you look at github samples and maually edit vcxproj file. Otherwise it was not generating the .idl, .h and .cpp files for new user controls. tool was randomly renaming them to xaml.h and xaml.cpp and also not generating stubs for idl files, and generating stubs for already deleted .idl files). This needs a fix yesterday!
@robertsi I'm sorry you had a bad experience with our docs. @marb2000 can you take a look at these to update the docs?
@azchohfi Well It is mentioned in Host a custom UWP control in a C++ Win32 app(https://docs.microsoft.com/en-us/windows/apps/desktop/modernize/host-custom-control-with-xaml-islands-cpp), but as I was first trying to get the basics working I was unnecessary scratching my head for a few hours. But a far bigger issue was that the wizards for adding items are not working!
Following wizards:
produces almost nothing and mess project up. Event viewmodel.idl is not picked up as it generates nothing, then I have to fix it all by manually editing .vcxproj project files, looking at examples in github...I also tried to do a complete uninstall/reinstall of visual studio 16.5.3....result is the same...
KR, Robert
It's a Visual Studio regression in C++/WinRT. I have informed them, waiting for a response.
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established.
I just ran into this while trying the example on https://docs.microsoft.com/en-us/windows/apps/desktop/modernize/host-standard-control-with-xaml-islands-cpp based on a new project using the "Windows Desktop Application" C++/WinRT template.
As above, I worked around it by adding #undef WIN32_LEAN_AND_MEAN
at the top of the .pch in the project. Thanks @robertsi !
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established.
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established.
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established.
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established.
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established.
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established.
It seems that #undef WIN32_LEAN_AND_MEAN was causing this issue. We updated the doc: https://docs.microsoft.com/en-us/windows/apps/desktop/modernize/host-custom-control-with-xaml-islands-cpp
Hi!
I tried to create a standard win32.dll that creates a win32 thread+ window and uses xaml islands.
I debugged the dll....and it fails on
auto interop = desktopSource.as<IDesktopWindowXamlSourceNative>();
with error hresult_no_interface at memory.KR, Robert