AngularJS – Architecture ideas

Hi, This post is about some general guidelines I use when designing my AngularJS projects.  Why a single page app? You write an MVC based app, which is modular and easier to test, deploy and manage. State is handled by the client, server code is simple (no client logic). A better architecture, where the client […]


AngularJS – useful libraries

Hi, Here are some useful angularjs libraries that I use often. Routing and State Management angular-ui Mobile and touch angular-gestures Browser detection and capabilities modernizr This is a work in progress. Have any angular libraries you like – post them in the comments please. J.


AngularJS – performance tips

Hi, Here are some performance tips when writing angularjs apps. Reduce the number of filters in your views Keep the number of “watches” down. Consider using something link bindonce. This is not angularjs, but use paging – keep your DOM small. Limit and batch your network requests. Use $templateCache by implementing grunt-angular-template Have useful performance tips. […]


Silverlight 5 pInvoke USB/Removable Drive detector

Hi, A friend of mine asked me if an elevated trust Silverlight 5 application could monitor windows events, specifically when a USB drive is inserted or removed. I naturally said YES, knowing that pInvoke is supported, but decided to take a few moments to write some code. After searching the web I found a great […]


Create shortcut to SL5 OOB App

Hi, I’m loving the power of Silverlight 5 Out of Browser (OOB) applications, now with improved file access and pInvoke. Thinking about deploying an OOB app to my users, I was wondering if I could create an OOB app that would launch itself when the OS starts. Looking at how a user invokes the “Install […]


Silverlight 5 pInvoke USB/Removable Drive detector

Original post: http://www.netusup.com/2011/12/31/silverlight-5-pinvoke-usbremovable-drive-detector/ Hi, A friend of mine asked me if an elevated trust Silverlight 5 application could monitor windows events, specifically when a USB drive is inserted or removed. I naturally said YES, knowing that pInvoke is supported, but decided to take a few moments to write some code. After searching the web I […]


Silverlight 5 (OOB) Win32 API GetLogicalDriveStrings

Hi, Starting to use Silverlight 5 and enjoying P/Invoke! We needed the ability to list drive letters on the user’s computer. Using System.Runtime.InteropServices, we imported the GetLogicalDriveStrings method. Then we created our own GetLogicalDrives() method which extracts the drive letters from the buffer that is returned. Here’s the code: using System.Runtime.InteropServices; using System.Windows; using System.Windows.Controls; […]


SL_Logo_thumb.jpg

How to set Foreground of DataGrid Column with ValueConverter

If you need to change the Foreground (Color) of a DataGrid Column based on its value you will probably encounter a problem when you try to bind your DataGridTextColumn.Foreground property to a ValueConverter. I’ll show you how we do it and hopefully save you an hour or two. Tools used? Visual Studio 2010 Silverlight 4 […]


WCF RIA Services, DataGrid Filters NO DomainDataSource

  So many of the Silverlight samples use minimal code in an attempt to use controls, binding and commanding techniques to create application by just using markup. Although these techniques are cool and may be great for rapid prototyping of an application, our team prefers to write code that gives us access to the details […]


Silverlight solves our deployment problems. 6

Mature Architecture + Easy Deployment + Great UX = SILVERLIGHT When ever I am approached to help design or improve an architecture for a system, one of the first issues I ask about is deployment requirements. I generally like to choose the technologies that require writing the least amount of code to deliver a feature: […]