473,403 Members | 2,270 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,403 software developers and data experts.

dynamically determine .net baseframework version of exe or dll

Hi All,

Whether in a Winform application (.exe) or a .Net assembly (.dll), is there
a way to determine what version of the .net baseframework the run-time
module (i.e. exe or dll) was loaded with (is using)? Seems that using
reflection this is possible...just can't seem to figure out what
classes/instances will get me there. Thanks in advance!

Tony
Nov 26 '06 #1
3 1338
Anthony,
>Whether in a Winform application (.exe) or a .Net assembly (.dll), is there
a way to determine what version of the .net baseframework the run-time
module (i.e. exe or dll) was loaded with (is using)?
System.Environment.Version
Mattias

--
Mattias Sjögren [C# MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
Nov 26 '06 #2
If you are looking for a non-programmatic way you can enable CLR Load
Logging which I blogged about
http://pointerx.net/blogs/glozano/ar.../03/23/84.aspx

Gabriel Lozano-Morán

"Anthony LaMark" <an*****@eXcSoftware.comwrote in message
news:Oi*************@TK2MSFTNGP03.phx.gbl...
Hi All,

Whether in a Winform application (.exe) or a .Net assembly (.dll), is
there a way to determine what version of the .net baseframework the
run-time module (i.e. exe or dll) was loaded with (is using)? Seems that
using reflection this is possible...just can't seem to figure out what
classes/instances will get me there. Thanks in advance!

Tony

Nov 28 '06 #3
Hi

The framework library, that includes .exes and .dlls, (eg :say
System.dll) are .net assemblies.... So you can always query the
metadata of assebmly through reflection.

hope this is helpful

Thanks
-Cnu
Anthony LaMark wrote:
Hi All,

Whether in a Winform application (.exe) or a .Net assembly (.dll), is there
a way to determine what version of the .net baseframework the run-time
module (i.e. exe or dll) was loaded with (is using)? Seems that using
reflection this is possible...just can't seem to figure out what
classes/instances will get me there. Thanks in advance!

Tony
Nov 28 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: George Hester | last post by:
Say I have this in a web page: <center><a href="http://www.microsoft.com">www.microsoft.com</a></center> I can use CSS, the DOM and\or JavaScript to determine the width style.innerHTML.length...
1
by: Andy | last post by:
Can anyone tell me if it is possible to dynamically create generic collections? simply put I want to be able to something like this : public object test(SomeBaseClass param1) { if...
4
by: david | last post by:
I have an array of CheckBoxes which dynamically display in a web form. How to detect and determine which CheckBox' check status changed? For example, Array(i, j) from checked to Unchecked and...
6
by: Samuel R. Neff | last post by:
How can you detect the version of windows common controls installed at run-time? I want to implement the ListViewXP (flicker-free) but still need to support non-XP computers (which will have...
3
by: Anthony LaMark | last post by:
Hi All, Whether in a Winform application (.exe) or a .Net assembly (.dll), is there a way to determine what version of the .net baseframework the run-time module (i.e. exe or dll) was loaded...
8
by: BillE | last post by:
When I create a control dynamically and it grows according to the content, the control Height property still returns the original default control height instead of the height after expanding. ...
2
by: Nathan Sokalski | last post by:
I have LinkButtons that are dynamically created in one of the PostBack events. They must be created in the PostBack event because one of the variables required to determine which ones to create...
9
by: =?Utf-8?B?VGhvbWFzIFcuIEJyb3du?= | last post by:
"parez" wrote: Assembly.LoadWithPartialName does indeed work!! Now, why is this incredibly useful routine deprecated and we are instructed to use Assembly.Load instead which does not provide...
4
by: ameshkin | last post by:
Hi Everybody, I'm just now learning javascript and I'm using mootools. What I want to do is to dynamically load a php page into accordian panel 2, depending on which radio button is selected in...
30
ADezii
by: ADezii | last post by:
This week’s Tip of the Week will clearly demonstrate how you can dynamically set the Drop Down List Width of a Combo Box to the length of the longest item in its Row Source. The inspiration for this...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.