Windows Store apps: StreamSocket connection to localhost
The problem: running unit tests on a Windows Store app that connects to a port on localhost results in the error "A connection attempted failed because the connection party did not properly respond after a period of time ...". Connecting to a loopback address (127.0.0.1 or localhost) is not supported in a Windows Store application. Period. However, connecting to localhost while debugging an application in Visual Studio IS supported. ...
Windows Store Apps: Threads to Tasks
If you're updating an old .NET code base to a Windows Store app, you may notice that the Thread class is no longer available. Instead, we have the more sophisticated Task. If you have a lot of Thread usage in your old code, you may find a re-write of the threading code to be a large task (sorry). Here's some code that you can use in place of the missing Thread class. This uses Tasks under the hood: using System; using System.Thre...
Windows Azure: Where is my stuff?
So you’ve deployed an application to Azure. If you login to the deployment with Remote Desktop, your first question might be “Where is my application installed?”. There are three disk drives in the deployment. Drive C: contains your local storage folders Drive D: is the operating system Drive E: contains your application files Local Storage Folders In C:\Resources\Directory, you will see each of your local storage ...
Windows Azure Deployment Tips & Tricks
I’ve run into a few gotchas when deploying to Azure. Missing DLLs. Not all “system” libraries are included in the Windows Azure run-time environment. If you use any of these, make sure to mark them as CopyLocal=true in your project. The one I always forget is EntityFramework.dll. Folder permissions. If you add local storage folders to your deployment, you might be surprised to find that when logged in to the deployment ...
PDX Code Camp Session: WP7 Tips & Tricks
I presented the Windows Phone 7 Tips & Tricks session with Allen Newton yesterday at Portland Code Camp. Good times. In our talk we showed a sample application "PDX Chow" that demonstrates a number of phone development concepts: MVVM architecture with Laurent Bugnion's MVVM Light Panorama control Inversion of Control / Dependency Injection Navigation using commanding and context Page orientation events Accessing ...