0

I have a Silverlight 5 application and needs to check the client side operating system type if it's 32bit or 64bit OS.

Environment Class dosen't help.

I used the code

//C# Code

var bitSize = IntPtr.Size * 8; // returns 32

But, it return 32 while the OS is Windows 7 Enterprise SP1 64 bit base on the system property. START>Computer>System Properties>

What is wrong with my code.

mercu
  • 121
  • 2
  • 16
  • Its its running on a web page can you send the user agent to silverlight? – Adam Jul 23 '13 at 10:27
  • It's running in Web page. We set the application to not support the out-of-browser functionality. For query "can you send the user agent to silverlight?" - can you please elaborate more. I didn't userstood what you mean. – mercu Jul 23 '13 at 10:40
  • 2
    Take a look at this question: http://stackoverflow.com/questions/1403727/how-to-detect-the-os-from-a-silverlight-application A user agent contains loads of details, so you could print it on the page from ASP or PHP then silverlight can pick it up. An example agent is this: Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.72 Safari/537.36. I believe if it says WOW64 then its windows 64bt http://www.whatsmyuseragent.com/ – Adam Jul 23 '13 at 10:47

0 Answers0