How do I determine the .NET framwork version in a partial/medium trust environment?

Posted by Ezombort on Stack Overflow See other posts from Stack Overflow or by Ezombort
Published on 2010-03-18T08:03:26Z Indexed on 2010/03/18 8:11 UTC
Read the original article Hit count: 373

Filed under:
|
|

I need to determine the clients .NET framework version in my web application. I'm running in partial trust so I can not read the filesystem or registry (Is there an easy way to check .net framework verison using C#?).

  • System.Environment.Version returns the runtime version, so I can not use that.

  • I cannot use javascript

The only way I can think of at the moment is to try to load a .NET 3.5 dll and catch an exception, but this does not sound very nice.

Any suggestions?

© Stack Overflow or respective owner

Related posts about ASP.NET

Related posts about c#