The problem is solved. It turns out that i was not a x86 issue and it doesnot encounter only on windows vista. The same problem/error was observed on windows xp but there there was an error signature showing up. In Windows vista i had to inspect the error from the event handler. The error showing was something similar to this:
Event Type: clr20r3 P1 :HelloWorld.exe P2 : 1.0.0.0
P3: 515b6326 P4: system.data.sqlserverce P5 : 4.0.0.0
P6: 4fcd17f1 P7: 8f0 P8: 25
P9: System.windows.markup.xamlparse
After searching i found that the solution was to install this Microsoft update on the machines http://www.microsoft.com/en-us/download/details.aspx?id=26368