Cider – A Bitter Brew
Cider is the name for that incredibly slow and useless XAML preview in Visual Studio 2008. Instructions on how to turn it off can be found here.
Cider is the name for that incredibly slow and useless XAML preview in Visual Studio 2008. Instructions on how to turn it off can be found here.
The MVPoo (or M-V-poo to be more precise as defined by its creator, Dr. WPF) pattern recognizes the fact that there is a difference between the ideal world and the real world so that nice and clean implementation of the MVVM(C) pattern is not always achievable

via Microsoft UK Application Development Consulting
Why PowerShell Hacker? Why Not?
I like Jeffrey Snover’s tweet – Become a first follower and join the dance! http://www.youtube.com/watch?v=fW8amMCVAJQ&sns=em
It’s a standing joke on my current Silverlight project that when something isn’t working, just try Dispatcher.BeginInvoke.
Its funny because its true. When there’s property setting or UI resizing or several other common UI related problems, putting the next statement on the Dispatcher to let an operation complete first is just the trick. Handy as Duct Tape. Case in point, the focus at startup issue.
On a recent client engagement; we were asked to conduct a POC of automation tools against a Silverlight 3 GUI.
As an out of the box solution, QTP (version 10) did not provide sufficient granularity with respect to Silverlight object recognition.
Having already been required to install the .Net and WPF plugins, research and contact with HP uncovered the need for three additional patches to be installed; before the spy tool could actually drill down through the Silverlight Window to identify object properties.
Once up and running; one of the noticeable differences between QTP and one of the other tools we evaluated (ArtofTest DesignCanvas 2.0) was the slowness of script capture.
I finally figured out the way to set focus to a Silverlight control on start-up: just set focus to your app, then set the control focus on the dispatcher to give the app time to process whatever it needs to when it gets focus. In other words, in the root visual constructor use this code:
HtmlPage.Plugin.Focus(); Dispatcher.BeginInvoke(() => YourControl.Focus());
This may be the first (and probably the last) actual Silverlight mystery I have solved. A couple months ago, I was searching the internet for the way to do this and found absolutely nothing.
Yippee-Kai-Yay for me
Flash vs Silverlight vs HTML5; a no-holds barred grudge match is brewing in this industry. It will divide developers and companies where there was little contention in the past. I doubt that this will end in a fatality, but the injuries will most likely fall to Adobe because of its current dominance in the field. Each technology has its pros and cons, and multiple providers can co-exist, but companies need a reason to choose one over another. I predict most of the debate will be based around the development process; ease of development, quick prototyping, effectiveness of tools offered, development environments, unit testing, system integration, as well as application design and planning. If a company can make great applications in less time, it means that they can make more money.
I just made my first Visual Studio snippet. It’s really easy.
There’s a consensus developing that says dependency properties are usually too heavyweight and people are using INotifyPropertyChanged instead. I miss the snippet that creates a dependency property, so I made a similar snippet for INotifyPropertyChanged. You can download the code here.
To make a snippet, just go to Tools / Code Snippets Manager and find a snippet to start with. I started with the “Define a Dependency Property” snippet since I was doing almost the same thing. The Snippets Manager will tell you where that file is:
Thanks for a the great conference Microsoft. Showing that as a large company they can still innovate. Azure, Siliverlight 4, Office 2010, Dallas, AppFabric and much more.
I finally go to shake the hand of Jeffrey Snover, the man behind the vision of PowerShell. We got to chat for a few minutes before he was on the panel Microsoft Perspectives on the Future of Programming. Some great thinkers on the panel, Butler Lampson, Erik Meijer, Don Box, Jeffrey Snover, Herb Sutter, Burton Smith. Covered Parallel programming (we’ll still be figuring it out in the next 5-10 years), textual DSLs, modeling, importance of glue languages and more.
Went to the .Net Meetup Tuesday night and had a great time. Plenty of interesting discussion and some laughs too. (All that and free pizza too). Highly recommended:
if (yourGeekiness >= myGeekiness)
Daniel Chait (my boss
led the meeting. The below info is mostly from Dan’s notes which he wrote on the overhead in real-time (I take credit for any errors or omissions). As you can see, if you didn’t attend, you missed a lot. These are mostly just the topics. Each one generated lively discussion:
PDC 2009 started today:
i think silverlight just swallowed wpf from the inside
Reading the feature list of the upcoming Silverlight 4 release (now in beta), I am more than a bit impressed. Up to now, there has been a few glaring features by which Silverlight was trailing behind Flex – camera/mic input; printing; clipboard access; and right-to-left text being ones that spring to mind. Admittedly, all of these are fairly niche features which most applications wouldn’t require.
A weekly roundup of interesting things I hear about at the Lab, since this is the first one, it covers a bit more than a week.
A couple of Flex developers commented that WPF and Silverlight are so much more mature, easier and feature rich. They were half right as this popular diagram shows:
Some UX designers working with Expression Blend said it’s not horrible, so now I don’t feel too bad asking them to use it.
This fun character interaction chart was much discussed (small version here). I think it gives an interesting summary of some great movies. It may bear a resemblance to the Napoleon March Map.
I have a Silverlight application consuming a WCF service. And as you may know WCF errors are not serialized on the Silverlight side and all you get is generic NotFound error.
I was experiencing the error only in certain rare cases.
Everything seemed fine in the WCF side, no exceptions were thrown in my service contracts.
I fiddled with the Fiddler but that did not capture anything.
I fixed the issue purely by divide/conqure method. Turns out I was passing an object with an enum type property, but was never setting that property. The debugger showed that the value of the enum property was the first item in the enum as one would expect.
However, when I explicitly set the property it all started to work!
Just reading about the efforts to produce an Eclipse-based Silverlight development platform for the Mac – quite cool.
I have to think though, perhaps the effort would have been better spent creating a port of Blend for the Mac… it seems to me that only a tiny minority of developers would opt for Eclipse over Visual Studio; whereas I’d guess nearly all designers would prefer to work natively within MacOS.
I can kind of understand why they’ve done it, but I can only hope there’s another project underway with that Blend port…
When it comes to video delivery, I come from a Flash background. I’ve worked on numerous streaming video projects over the years, all of which were created with Flash & Actionscript on the client side. Having been through the process several times, I know all the hurdles I’m going to have to clear well in advance.
Documentation for coding a Silverlight 3 player against IIS Smooth Streaming is a little sparse. IIS.net has several articles on the server setup, but I couldn’t find anywhere obvious regarding the client connection.
This one was driving me crazy for at least a few hours. On a fresh install of VS2008 & Silverlight 3 tools, there was no xaml code highlighting at all, no intellisense, nothing – just like any ordinary text file. Checking the same project on another machine, it was all fine. So I starting disabling/uninstalling all VS plugins (ReSharper, AnkhSVN), but still no luck. Was starting to think I’d have to reinstall VS…
The solution was simple enough – run the VS Command Prompt, and enter:
devenv /resetskippkgs
Problem solved. Apparently a good one to try whenever you lose formatting or Intellisense features.
Michael Foord, author of IronPython in Action, is creating a ‘Try Python: Interactive Python Tutorial’ site. Built with Microsoft Silverlight and IronPython.
He presents a Fibonacci example and demonstrates multiple assignment for variables.
In this PowerShell example, the second line sets the variables a and b to 0 and 1. Then again in the sixth line. Notice that the expression ($a+$b) is evaluated and then assigned.
Function Fibonacci($n=10) { $a, $b = 0, 1 while($b -lt $n) { $b $a, $b = $b, ($a+$b) } } Fibonacci 20