46 ms·
My only concern would be supporting older versions of windows while utilizing features where available. Would have been cool to see an example of doing this in
by tracker1 10y ago
My only concern would be supporting older versions of windows while utilizing features where available. Would have been cool to see an example of doing this in the article.
Just the same, it's cool that it can be added without having to completely migrate/rework an application.
- dmitrygr 10y agoSee last few paragraphs.
- becarefulyo 10y agoThe Windows 10 API provides API availability checks. So you target the latest version but then add checks to see what API's are available. This is nice because it encapsulates both OS version API differences and device capabilities. https://blogs.windows.com/buildingapps/2015/09/15/dynamically-detecting-features-with-api-contracts-10-by-10/ https://blogs.windows.com/buildingapps/2015/09/15/dynamicall... using Windows.Foundation.Metadata; if(ApiInformation.IsTypePresent("Windows.Media.Playlists.Playlist")) { await myAwesomePlaylist.SaveAsAsync( ... ); } if(ApiInformation.IsApiContractPresent("Windows.Media.Playlists.PlaylistsContract"), 1, 0) { // Now I can use all PlayList APIs }
- rymate1234 10y agoUnfortunately that's a Windows 10 API, meaning it isn't very useful for older versions of Windows!
- becarefulyo 10y agoIn that case, you put your Windows 10 stuff in a different .dll that doesn't get deployed on old versions of Windows. The article has an example.