MicrosoftDocs / windows-dev-docs

Conceptual and overview content for developing Windows apps
Creative Commons Attribution 4.0 International
666 stars 1.18k forks source link

Possible change in method, not working #5018

Closed watson128 closed 4 weeks ago

watson128 commented 1 month ago

Type of issue

Code doesn't work

Feedback

I have copied the instructions to develop the C# Windows SDK app, PhotoViewer. I have completed all the instructions but when I run the app I get: image

Page URL

https://learn.microsoft.com/en-us/windows/apps/get-started/simple-photo-viewer-winui3?tabs=cs

Content source URL

https://github.com/MicrosoftDocs/windows-dev-docs/blob/docs/hub/apps/get-started/simple-photo-viewer-winui3.md

Author

@stevewhims

Document Id

51e8cf41-f09a-864d-26de-66d17727ebfc

stevewhims commented 4 weeks ago

Hi, @watson128. There's some disparity between your screenshot and the topic that you link to. So here's what I did:

  1. Your screenshot is showing the source code for the PhotoEditor sample app. So I cloned and built that sample, and it works fine. I don't get an exception on the line of code that you highlight.
  2. Your issue description mentions a thing called "PhotoViewer". I'm not aware of a sample with that name. But you link to the "Tutorial: Create a simple photo viewer with WinUI 3" topic (which builds a project named SimplePhotos, which seems to be the name of your project). I followed all of the steps in that tutorial from top to bottom, and everything worked as expected.

I'll go ahead and close the issue.

Thanks! -Steve