Yet Another Coding Blog

A Redmond dev blog... from Sydney; by Avi Pilosof.

Browse by Tags

Tagged Content List
  • Blog Post: Development Tip – Dispatching calls to the UI thread

    In Silverlight and WPF, if you wanted to update the UI from a thread you had launched, it was important that the UI update be executed on the UI thread, lest you get an invalid-cross-thread-access error. You could ensure this by initially getting a pointer to the dispatcher for the UI thread, and...
  • Blog Post: Development Tip – Tab Control

    I'm trying to replicate a tab control in the Windows 8 //BUILD release. I’m not talking about your traditional tab control with grey tabs and a static appearance; rather something that we’ve seen throughout the demos at //BUILD; a set of clean links at the top of the app that flip to different...
  • Blog Post: Development Tip – Packaging and loading files

    In Windows 8 I want to have a file in my solution which is packaged as part of the application, then read at runtime. It’s not immediately obvious how to do this because the app is running in an environment we’re not used to, and using StorageFile.GetFileFromPathAsync doesn’t let you...
  • Blog Post: Development Tip - ObservableCollection doesn't work

    NOTE: This post applied in an the early preview of Win8. It's no longer applicable because the bug in question no longer exists; ObservableCollection works just great :) Original article below. Just getting started with Win8 development, and will note what I learn in a series of posts. ...
  • Blog Post: Useful C# method for unit testing

    I’m unit testing a UI that needs to show some lists in various sorted orders, and I wanted to ensure that my tests would cover that. I found this method to come in handy:   1: public static bool IsOrderedBy<T>( this IEnumerable<T> coll, 2: Func<T, IComparable> val) 3...
  • Blog Post: Live Mesh Applications – whoah.

    I’ve been playing with Live Mesh for a long time now, and have been loving it. During this time I’d been hearing about applications for Live Mesh, and while it sounded interesting in theory I didn’t really get what the point would be. Then I watched this video: http://briangorbett.com/mesh/mesh-video...
  • Blog Post: Be Paranoid. Be Very Paranoid.

    Do you maintain an application with a backend database? Does that application ever write to the database? Be afraid. The worst situation to be in with respect to the above is when a customer mails you and says: “Why is my data gone?” 99% of the time, it’s because they clicked on the “Delete” button;...
  • Blog Post: Trivial but useful extension method

    Don’t know why I didn’t write this before; it makes code very readable. Often when you write anything graphics related, you want to constrain coordinates to window edges (for example). So a simple method: 1: /// <summary> 2: /// Ensure that the given number falls within the 3: /// given...
  • Blog Post: On using Arrays

    Eric Lippert has a great article on arrays: http://blogs.msdn.com/ericlippert/archive/2008/09/22/arrays-considered-somewhat-harmful.aspx   I think this is especially useful to consider if you’re writing an API. Consider not just arrays, but any time you’re returning any collection: Are you returning...
  • Blog Post: Code commenting? Try Business Commenting.

    Jeff has a good post here about code comments and that they shouldn't be used as crutches: Coding Horror: Coding Without Comments I agree with the article, but one thing I rarely hear mentioned is that it's often more interesting to comment the business justification than it is to comment the code. Jeff...
  • Blog Post: Australia is going to France!

    (Bonus points for misleading title) The Australian Team SOAK just made it into the finals of the Imagine Cup. They were one of the 6 teams chosen in the Software Design Category. This year's theme was "The Environment", and Team SOAK has written software to monitor/control water usage on farms...
  • Blog Post: It's all just a clock measuring contest...

    Did you know that SBCL is now faster than Java, as fast as Ocaml, and getting better ?! What does this mean for you? Most likely, nothing. They have various benchmarks that are used to measure the speed of a language implementation; and I think it's a good thing - it keeps the implementers honest, and...
  • Blog Post: Can Software be Reliable?

    Just read a post (permalink is broken) regarding how software engineering is nowhere near the level of quality as traditional engineering, partially because we don't have standards, regulations, etc. While I agree with some of the argument, people often give too much credit to meatspace engineering when...
Page 1 of 1 (13 items)