Jim W
Jim W

Reputation: 5016

Which project file element specifies a WinRT class library project and not .NET?

I have a WPF class library that I want to port to be a WinRT class library. My plan is to copy the project, edit the project file so that it's a WinRT project instead of WPF, and see where I stand.

However, I cannot find which element in the project file makes it a WinRT project, and not .NET. Any ideas?

I've tried everything including diffing the project file with a WinRT class library project file, and slowly changing it over, but the WPF project never switches to WinRT in VS's eyes.

Sorry if this sounds nuts, I'm looking for the quickest way to find out how much work I need to do to port across.

Thanks

Upvotes: 0

Views: 330

Answers (1)

Damir Arh
Damir Arh

Reputation: 17855

I'd take a different approach to that:

  • First I'd create a new Windows Store apps class library project.
  • Then I'd copy all the files from the existing WPF class library folder to the new Windows Store apps class library project folder (without overwriting any of existing files)
  • In the Solution Explorer window I'd enable Show All Files to see all the copied files and folders.
  • I'd multi select all the items in the treeview that belong to the project and click on Include In Project from the context menu.

At this point the only thing potentially still missing would be settings at the project level such as conditional compilation symbols and missing references which could easily be added by comparing both projects in Visual Studio or just trying to compile the new projects and seeing what goes wrong.

Upvotes: 1

Related Questions