Archive for the ‘Development’ Category

Finally I am back after a Loooong time away from my blog.

Actually I have been very busy in the latest months/years building new awesome stuff with my team during the day, and with my family during the rest of my spare time… for this reason I had really no time to write posts on my blog.

I am going to discover MS Azure in depth. I think this Cloud Infrastructure will be the best, I think they offer really unique and realitively cheap services compared with other cloud providers.

Yes, it is now the time to start discovering how migrate to build a SAAS solution on this infrastructure.

Keep in touch I’ll be back with some thoughts and I’ll post some updates soon!


Read Full Post »

These days I’m working mainly on Visual Studio 2012 RC and since we use Xsd2Code, I thought about why can’t I have it running there?

Basically VS 2012 RC is really similar on the Add-Ins model (from what I understand it didn’t change a lot from the 2010 release).

However if you try to find it through NuGet you can’t find it, and if you install the CodePlex package you see that actually it does show up on earlier versions of Visual Studio, but not on Visual Studio 2012.

I tried to hack this stuff and “published” the AddIn manually by changing some files, and it looks like it’s working.

Install from here:


Here you go:

  • Find the folder “AddIns” on your personal Visual Studio 2010 folder. You should have the same file as shown here:

  • Now, move on the “Visual Studio 2012” folder, and copy the same Addin file as shown above (remember to create AddIn subfolder if not found).
  • Edit the AddIn file by adding the section highlighted below.

There you go!

Start Visual Studio 2012, and see that the tool is available on the AddIn manager.

Update: Darin asked me to add the file directly for those that don’t have Visual Studio 2010 installed on their machine, but only 2012,  here you go … from codeplex, for the VS 2010 version, apply the changes above and you’re done

Have fun with this great tool!

Read Full Post »

Yesteday I had a very strange behavior. I had to build an installer package to update a web application in a customer site, but got crazy trying to have it installed correctly.

The application installed fine, but as soon as I tried to browse it, a strange error appeared on the EventViewer:

Type : System.ArgumentOutOfRangeException, mscorlib, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089
       Message : Specified argument was out of the range of valid values.
Parameter name: utcDate
       Source : System.Web
       Help link :
       ActualValue :
       ParamName : utcDate
       Data : System.Collections.ListDictionaryInternal
       TargetSite : Void UtcSetLastModified(System.DateTime)
       Stack Trace :    at System.Web.HttpCachePolicy.UtcSetLastModified(DateTime utcDate)
          at System.Web.Handlers.AssemblyResourceLoader.System.Web.IHttpHandler.ProcessRequest(HttpContext context)
          at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
          at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

What was happening?

Well, it appears that there is a problem with assemblies compiled in the “future”. Obviously this means that if you’re deploying an application on another timezone you must the coherency of the date/time of your assemblies with the actual date/time of that server.

In fact, IIS looks for the date/time of your assemblies, and if the date/time of your assemblies is on the future compared with the local date/time then it crashes with the exception above.

Hope this helps someone else having this issue.

Read Full Post »

The first demo of Windows 8 produced an indredible reaction of Silverlight developers having the sensation that Silverlight being dropped while promoting HTML5/CSS3 and Javascript as a new “first class” framework for the new OS.

I think that Silverlight and WPF are superior for many reasons compared to HTML5 and JS, as they are TODAY.

The reasons are:

  • XAML is BY FAR more elegant way to define UIs
  • Silverlight can completely re-template UIs easily
  • Building complex LOB applications. KnockOut JS is great, but not enough.
  • Silverlight is FAR more performant compared to ANY JS engine
  • Debugging HTML/JS app is a nightmare
  • JS is a dynamic language. Dynamic languages are powerful… but it’s extremely easy to lose control on your code.

Basically my thought are that HTML5/CSS3/JS is GREAT to build dynamic web sites, BUT when comes to write real/very complex LOB applications, then there are great limitations, at least TODAY. (please look at this great @shanselman blog regarding this stuff: Should I use HTML5 or Silverlight? One man’s opinion).

Talking about HTML5/CSS3, the standard is not yet defined, and many browsers implement it in different ways creating problems…

Before switching to any HTML and JS framework, I guess we really need to wait for adequate tooling – such as Blend for example – and for sure a REAL standard.

So… what’s really happening here? Should I need to learn HTML5/CSS3 tomorrow? I think the answer is NO. And I hope too because really I hate it at least at its current status.

The “future” as I hope it

Actually I think that Windows 8 will support ALL the platforms, including Silverlight, and Silverlight will continue to be supported in the future, however I think for a number of reasons that possibly Microsoft will introduce a sort of “deployment target” to HTML5/CSS3/JS for any application and continue to provide a .NET language such as C# and .NET along with XAML.

Let’s see what’s the current scenario:

  • WP7 runs Silverlight
  • Visual Studio, Blend, and other tools are currently based on XAML/Silverlight
  • Silverlight is a subset of WPF with some limitations

There are a lot of tentatives of “PORTING” features like data binding and .NET from Silverlight/XAML to other “platforms”:

  • Script# attempts to convert C# in JS!
  • Knockout JS implements MVVM pattern on JS
  • Mono touch allows writing C# code and run on IPhone/Android for example.

Do you think that MS will re-invent ALL their tooling to suit HTML and Javascript?

Do you think that tomorrow WP7 will run both Silverlight and HTML5 apps built in completely different ways?

Is Microsoft probably working on a sort of “conversion tool” or runtime that will allow current tools, XAML, .NET to be converted in HTML/JS/CSS3? A new “deployment target”, … something like that.

OK, this sounds very difficult or full of limitations, … however I am quite sure that it isn’t impossible, given the points above.

We’ll see what will happen in the next months…

Keep tuned.

Read Full Post »

These days I came across Knockout. This GREAT library really provides necessary help for developers on building the next generation HTML5/CSS3 applications for both client and mobile platforms.

MVVM was firstly introduced on WPF and then on Silverilght to provide an intermediate mean for databinding a user interface to the underlying data model.

Today we can really provide the same experience also on browser applications, by doing databinding on HTML!

I have to say that with this library everything is different. This complementary library can work with JQuery and other frameworks.

Here you can look at how it works:


This library is very lightweight since is somewhat ~28Kb minified and 10 Kb compressed javascript.

Great Job Steve!

Read Full Post »

Today I experienced something that made me really angry against Visual Studio 2008 Profiler! I spent half a day to try find why a certain program was slow at determinate operations, I was focusing to some complex methods because profiler was pointing me there and I was seeing no other sign of issues around.

Well, after losing a lot of hours, Mizokunimito came into rescue and promptly remembered me to avoid trusting this profiler.

I said “You’re joking. If the profiler shows me that this method reports the major number of samples then is the place to look for optimizations… ok, … if the profiler is right, and I really hope so”.

Well, he was completely right on that, Profiler was cheating. Some method calls were COMPLETELY MISSING FROM THE REPORT, thus pointing us to look at the wrong direction.

We saw that by manually adding some StopWatch.Start/Stop calls, and dumping the timings on the method that profiler, the time required to execute that method was only a few ms, compared to the simulation that was saying more than 1500 ms!!

Now, I know and we use Visual Studio 2010 for other projects, but in this case we had to keep the Visual Studio 2008 project for a number of reasons, so we had to use an “old” version of the profiler, … but… I have to admit, …

I learned another time, that

1) We should never trust software too much , and be always as St. Thomas… trust only your eyes, and look also where you think that there are no issues… because sometimes Murphy Law helps making this the actual answer to your performance issues!

2) Working on a real Team is a great thing!


Read Full Post »

Great object programming should always employ SOLID object programming principles/patterns, because they allow among other things, better extensibility maintenance. This is especially true if you’re going to create an application or framework that evolves over time.

I would like to post some links where Julian M Bucknall (CTO of DevExpress) that explains the principles on these great videos:

"S" Single Responsibility Principle: http://tv.devexpress.com/#SingleResponsibilityPrinciple;.tag;1

"O" Open Closed Principle

"L" Liskov Substitution

"I" Interface Segregation

"D" Dependency Injection

Thank you Julian for providing such valuable videos.

Read Full Post »

Older Posts »