Programming

  • Helpful tools in Web UI Development

    Occasionally I come across a really useful tool, or some sort of feature/framework/idea that I think hey, that would be great to remember for future Web site development. So, here is a list of some of these that I would like to share: Nuget: A must if if you are developing in .NET. Nuget ensures that you can access the streams of modules and packages that are being written and distributed around the world. If you are still adding references to projects then you are potentially doing it all wrong (not necessarily of course). Nuget is a mainstream of Visual Studio and Microsoft tool development now. Build servers (Continuous integration…

  • Yet another custom binary protocol library implementation

    Recently I have been involved in a project that required a custom binary protocol specification be written for interaction between some custom hardware and a central processing server. Before you wonder why re-invent the wheel I did look into protoBuf but although perfect for what I was doing, implementing this on the custom hardware would have been more difficult. The communication was going to occur over TCP using sockets. Some of the requirements of this protocol included: 1. A small size protocol to minize network traffic 2. Libraries that could be used across multiple applications to handle the protocol 3. An extendable protocol so that new packet types could be…

  • Calling .NET MVC 3 action method via jQuery ajax and handling serverside redirect

    Recently I developed a .NET MVC 3 application where jQuery would be a core part of the design and it was accepted that we did not have to worry any special optimization for phone or mobile devices or disabling of javascript. During development of this application I wanted to make use of page redirects while using the inherited .NET Controller RedirectToAction() method. This worked well. When making HttpPost or HttpGet requests I would do the standard re-direct as necessary and everything worked as I would expect. However, as mentioned the majority of our requests were via jQuery ajax. And not only that, the responses to the ajax request would vary…

  • ViewModel composition and using Partial views with Partials

    Slightly confused by the title of this topic? I can see why. Even I didn’t know what to give the name to the problem a recent problem I encountered and I ended up resolving it. Instead I’ll try and state the problem in my definition below: Please note. There might be better ways of doing this, or perhaps I’m doing it all wrong. Take this with a grain of salt and if it works for you, that’s great. Otherwise that’s great too… History Whilst being new to MVC .NET I did alot of reading on best practices, any practices and different methods of using the concept to achieve my desired…