Skip to content

Window.As<MainWindow.IWindowNative>()' cannot be accessed with an instance reference #3289

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ghost1372 opened this issue Aug 10, 2021 · 1 comment

Comments

@ghost1372
Copy link
Contributor

I want to test the new API At first I had a little problem that I solved Now I get the following error

error CS0176: Member 'Window.As<MainWindow.IWindowNative>()' cannot be accessed with an instance reference; qualify it with a type name instead


Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

@ghost1372
Copy link
Contributor Author

ok i fixed it with adding following namespace

using WinRT;

learn-build-service-prod bot added a commit that referenced this issue Feb 2, 2023
* Update SysCmd plugin: Recycle Bin command

* [PowerToys]Update Awake settings screenshot

* Update single-project-msix.md (#4255)

Update steps for converting a C++ WinAppSDK app using Windows Application Packaging to Single-project MSIX Packaging; setting `AppContainerApplication` to `true` is no longer correct.

* Fix typo in localize-strings-ui-manifest.md

* winget is not pre-installed on Win11

---------

Co-authored-by: htcfreek <[email protected]>
Co-authored-by: Jaime Bernardo <[email protected]>
Co-authored-by: Matt Wojciakowski <[email protected]>
Co-authored-by: Evelyn Wu <[email protected]>
Co-authored-by: Alvin Ashcraft <[email protected]>
Co-authored-by: Andy Zivkovic <[email protected]>
Co-authored-by: Learn Build Service GitHub App <Learn Build Service [email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants