Personally, I've got fingers crossed for the Windows Phone 10 release ...
Loading user information from Channel 9
Something went wrong getting user information from Channel 9
Loading user information from MSDN
Something went wrong getting user information from MSDN
Loading Visual Studio Achievements
Something went wrong getting the Visual Studio Achievements
@RamblingGeekUK: Run that code on your desktop Windows 10 device and it will throw an exception. That is not very 'universal'.
A small rant ...
Well I decided to dive in and take a look at re-writing one of my older Phone Apps as a Universal app for Windows 10. Nothing too complicated, just a stopwatch and countdown timer.
Came to the point of alerting the user. Well, I thought, if it's able to vibrate the device that should happen. So I looked up the code and found VibrationDevice.GetDefault(). Perfect, I thought, if there's a vibration device I'll use it and if there isn't a device I won't:
If you call VibrationDevice.GetDefault() on a Windows device, it doesn't return null, it throws an exception.
So trying to figure out if there is a vibration device available when there isn't one is an exceptional circumstance worthy of an error?
FFS, framework team, for things to be properly 'universal' you're going to have do fix querying for device capabilities better than this! Let me know when the frameworks finished properly.
I feel slightly better for getting that off my chest. Thanks.
Well, the 'correct' way to do it would be to re-query the database, just in case there are advanced techniques like calculated columns or triggered updates that would not necessarily show up in your entities before being saved.
However, that adds quite a burden to the database so you might just go with using the in-memory data in the first instance but try and structure the code in such a way that it will be easy to change to read from the database should the need arise in the future.
I still find myself using ADO.NET Datasets -- they're disconnected from any kind of 'session' and they keep their own change-tracking so you can pass them around easily for processing and then pass back for updating in the database. I have a library of extension methods to make them a bit easier to use and to optimise serialisation.
The only issue is a lack of async support which I suspect is more to do with MS resources than any technical reason. Have they open sourced ADO.NET yet?
Well, my own installation was not smooth -- Windows Update was failing to upgrade and giving a raft of different error codes which all seemed to be about Windows Installer rather than about the Win10 update.
Fortunately, I downloaded an ISO from MSDN and will apply that then I'm home tis evening. Frustrating for me as a technical user, however I can imagine a non-technical user not even noticing that anything was wrong (no 'Win 10 failed to install' messages or anything unless you look in the update history) and just either giving up or waiting and assuming it wasn't released for their machine yet. Hopefully MS sort these things out fast enough that no-one will really notice.