Detect which version of Visual Studio compiled a program

  • Thread starter Thread starter Barry Flynn
  • Start date Start date
B

Barry Flynn

Is it possible for a VB Win Forms program to detect whether it has been
compiled with VS 2005 or VS 2008?

Thanks

Barry Flynn
 
To my knowledge, such information is not kept in the assembly metadata.

Why do you have to perform this check; what has to happen in either case?
 
Thanks for the reply.

<< > Why do you have to perform this check; what has to happen in either
case?
Its just for informational purposes.
I need to keep some projects in both VS 2005 and VS 2008 for a while, and to
avoid doubling up coding & testing of changes, I would like to keep a single
set of source code in VS2005 which periodically gets copied into a VS 2008
environment and compiled.
In case I get myself confused, I was just considering ways to tell, with
certainty, which version a particular .exe had been compiled with.

Thanks

Barry
 
Barry,
Try using dumpbin. The PE headers used to contain the version of the
linker used to produce the file, and MS always changed the linker version
for each version of VS.
Bob
 
Back
Top