Sunday, August 2, 2015

Updating Win32 and 8.1 apps to Windows 10

Win32 apps:
  1. Open your project in visual studio.
  2. Make new configurations ReleaseWin10 and DebugWin10 by using the configuration manager and copying values from the existing configs.  This will let you continue to compile on older versions of windows.
  3. Right click each project and go to properties.  Find the "Platform Toolset" and change to Visual Studio 2015.
  4. snprintf behavior is different from _snprintf.  If you had a project define snprintf=_snprintf, you will need to remove that define and make sure your code expects the different behavior.  If you have an 8 size buffer and call _snprintf(buf, 2, "aa") you will get "aa)(#(!@".  If you call snprintf(buf, 2, "aa") you will get "a\0)(#(!@".
  5. Compile and cross your fingers.

Windows 8 Store apps:

  1. Watch this awesome video:
  2. Check to see if you have the UAP/UWP tools installed by looking in "\Program Files (x86)\Windows Kits\10\Platforms\UAP".  If that folder doesn't exist then download the Visual Studio installer, run it, and click modify.  Under features make sure "Universal Windows App Development Tools" is checked.  Go on vacation and come back in 2 weeks once it is installed.
  3. Make copies of your windows 8 projects in a new folder called something like Win10Projects.  This way the update is non destructive and you have a reference for how things should look.
  4. Update MSAdvertisingXaml Version 8.1 if necessary.  Open the project and look for a References folder.  Remove that reference.
  5. Go here and follow the instructions
  6. If you had any snprintf=_snprintf defines, remove them.
  7. Remove any ApplicationSettings:SettingsPane stuff.  
    1. [SettingsPane may be altered or unavailable for releases after Windows 10. Instead of using a SettingsPane, integrate settings options into the app experience. For more info, see Guidelines for app settings.]
  8. Remove any deprecated items from the AppxManifest.xml.  They will have a blue underline.

No comments:

Post a Comment