Skip to content
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

Error in code example #1193

Open
jgold6 opened this issue Oct 27, 2021 · 3 comments
Open

Error in code example #1193

jgold6 opened this issue Oct 27, 2021 · 3 comments
Assignees
Labels
doc-bug Problem with the content; needs to be fixed [org][type][category] dotnet-framework/svc okr-health Content-health KR: Concerns article defects/freshness or build warnings. okr-quality Pri2 Medium priority wpf/subsvc

Comments

@jgold6
Copy link

jgold6 commented Oct 27, 2021

The code example on step 9 of the To host the ActiveX control section has an error.

The line:
WmpAxLib.AxWindowsMediaPlayer axWmp = new WmpAxLib.AxWindowsMediaPlayer();
Should be:
AxWMPLib.AxWindowsMediaPlayer axWmp = new AxWMPLib.AxWindowsMediaPlayer();

At least I had to make that change or the above type would not resolve.


Document Details

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

@dotnet-bot dotnet-bot added the ⌚ Not Triaged Not triaged label Oct 27, 2021
@adegeo adegeo added the doc-bug Problem with the content; needs to be fixed [org][type][category] label Oct 28, 2021
@dotnet-bot dotnet-bot removed the ⌚ Not Triaged Not triaged label Oct 28, 2021
@adegeo
Copy link
Contributor

adegeo commented Oct 28, 2021

@jgold6 Thank you for reporting this. I confirmed this is true. Can you let me know what version of Visual Studio you're using? I'm using VS2022 and I had to also edit the com references in the project to disable embedding: <EmbedInteropTypes>false</EmbedInteropTypes>

Are you using a classic Framework project type or the newer SDK project types?

@jgold6
Copy link
Author

jgold6 commented Oct 28, 2021

@adegeo I used a classic .NET Framework 4.6.1 project type in VS 2019 (latest build), not using the SDK project type.

@adegeo
Copy link
Contributor

adegeo commented Oct 28, 2021

Thank you for confirming. Must be something you have to set on the new SDK Project type

@adegeo adegeo self-assigned this Oct 28, 2021
@dotnet-policy-service dotnet-policy-service bot added the okr-health Content-health KR: Concerns article defects/freshness or build warnings. label Jan 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
doc-bug Problem with the content; needs to be fixed [org][type][category] dotnet-framework/svc okr-health Content-health KR: Concerns article defects/freshness or build warnings. okr-quality Pri2 Medium priority wpf/subsvc
Projects
None yet
Development

No branches or pull requests

4 participants