To obtain the version of and assembly i go throught the reflection class and use the assembly.loadfrom("assemblyPath").getname.version.
This way implies to load the assembly.Is other way to read the manifest which don’t implies load the assembly
To obtain the version of and assembly i go throught the reflection class and use the assembly.loadfrom("assemblyPath").getname.version.
This way implies to load the assembly.Is other way to read the manifest which don’t implies load the assembly
Other ways to obtain the version of an assembly
macfarmw
No it doesn’t , the assembly persits in memory until de app end.
Brett H.
If you set the Assembly object to Nothing, then the garbage collector should dispose of it.
MyAssembly=Nothing
cgraus
Behnam Fagih
I always using something like
public string getVersion()
{
Assembly assy = Assembly.GetExecutingAssembly();
return assy.FullName.Split(",".ToCharArray())[1].ToString().Replace("Version=", "").Trim();
}
Neil P
Ulfaen
That’s ok when you want to now the version of the assembly your are currently executing, but i need to know the version of other assembly but i couldn’t not use the assembly.loadfrom() function because i need to overwrite that assembly whose I wan’t to know it’s version later.
Thank's for your help.