473,387 Members | 1,535 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,387 software developers and data experts.

Extracting Assembly Info

EdB
I want to use the Assembly information to display version/build information
and I have some questions.

I'm able to get the FileMajorPart, FileMinorPart, & FileBuildPart. I am not
able to get to the stuff like AssemblyProduct, AssemblyCompany, etc...

2nd, How does the FileBuildPart work. I don't see where it is tracked. I
would have assumed that everytime I rebuild the project or the solution it
would increment, but that doesn't appear to be the case. Even if I change
something. And how do you reset it (which you would want to do for a new
Major or Minor version).

Lastly, how is the FileRevisionPart used and how is it different from the
FileBuildPart.

Thanks in advance.

Ed
Nov 22 '05 #1
4 1564
The information you enter in the assemblyinfo.* class is added to the
assembly using an attributye so therefore you are going to have to extract
it from the assembly using reflection. The following example shows exactly
what you require.

http://winfx.msdn.microsoft.com/libr...1_f30c17d8.asp

As for the version numbers, if you change it from the default ( 1.0.*) then
it will not autogenerated a version number for you - the default is based
upon the current date and time. It is up to you how you want the version
number to increment with each release.

HTH

Ollie Riches
"EdB" <Ed*@discussions.microsoft.com> wrote in message
news:B8**********************************@microsof t.com...
I want to use the Assembly information to display version/build information
and I have some questions.

I'm able to get the FileMajorPart, FileMinorPart, & FileBuildPart. I am
not
able to get to the stuff like AssemblyProduct, AssemblyCompany, etc...

2nd, How does the FileBuildPart work. I don't see where it is tracked. I
would have assumed that everytime I rebuild the project or the solution it
would increment, but that doesn't appear to be the case. Even if I change
something. And how do you reset it (which you would want to do for a new
Major or Minor version).

Lastly, how is the FileRevisionPart used and how is it different from the
FileBuildPart.

Thanks in advance.

Ed

Nov 22 '05 #2
EdB
Thanks Ollie, although it sucks! I hate it when MS takes steps backwards.
In VB6, the Revision property of a project would auto increment with each
build. That's what I was after.

"Ollie Riches" wrote:
The information you enter in the assemblyinfo.* class is added to the
assembly using an attributye so therefore you are going to have to extract
it from the assembly using reflection. The following example shows exactly
what you require.

http://winfx.msdn.microsoft.com/libr...1_f30c17d8.asp

As for the version numbers, if you change it from the default ( 1.0.*) then
it will not autogenerated a version number for you - the default is based
upon the current date and time. It is up to you how you want the version
number to increment with each release.

HTH

Ollie Riches
"EdB" <Ed*@discussions.microsoft.com> wrote in message
news:B8**********************************@microsof t.com...
I want to use the Assembly information to display version/build information
and I have some questions.

I'm able to get the FileMajorPart, FileMinorPart, & FileBuildPart. I am
not
able to get to the stuff like AssemblyProduct, AssemblyCompany, etc...

2nd, How does the FileBuildPart work. I don't see where it is tracked. I
would have assumed that everytime I rebuild the project or the solution it
would increment, but that doesn't appear to be the case. Even if I change
something. And how do you reset it (which you would want to do for a new
Major or Minor version).

Lastly, how is the FileRevisionPart used and how is it different from the
FileBuildPart.

Thanks in advance.

Ed


Nov 22 '05 #3
Ed,

In my opinion is it nicely described by Microsoft.

http://msdn.microsoft.com/library/de...managevers.asp

I hope this helps,

Cor
Nov 22 '05 #4
EdB
Thanks Cor

"Cor Ligthert [MVP]" wrote:
Ed,

In my opinion is it nicely described by Microsoft.

http://msdn.microsoft.com/library/de...managevers.asp

I hope this helps,

Cor

Nov 22 '05 #5

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

Similar topics

10
by: Calvin FONG | last post by:
Dear all, Are there any utility that can be call by python to create self extracting zip file. I'm now using the powerarchiever. But the command line options aren't flexible enough. Basically, I...
2
by: Steve | last post by:
Hi, I have a very long string, someting like: DISPLAY=localhost:0.0,FORT_BUFFERED=true, F_ERROPT1=271\,271\,2\,1\,2\,2\,2\,2,G03BASIS=/opt/g03b05/g03/basis,...
2
by: Fritz Switzer | last post by:
Can anyone provide a small snippet in C# that pulls out the Contacts in Outlook XP. I've seen a couple of examples in C++ and VB in previous newsgroup posts, but either the originals didn't work...
5
by: Astra | last post by:
Hi All Is there an ASP way of extracting the height and width of a swf file so that I can specify these dims when adding the whole OBJECT code to the web page? Thanks Robbie
4
by: EdB | last post by:
I want to use the Assembly information to display version/build information and I have some questions. I'm able to get the FileMajorPart, FileMinorPart, & FileBuildPart. I am not able to get to...
11
by: Wolfgang Kaml | last post by:
I am not sure if this is more of an expert question, but I am sure that they are out there. I'd like to setup a general application or bin directory on my Win2003.Net Server that will hold some...
10
by: jojobar | last post by:
Hello, I am trying to use vs.net 2005 to migrate a project originally in vs.net 2003. I started with creation of a "web site", and then created folders for each component of the site. I read...
5
by: RickN | last post by:
I want to creat a new application domain called 'mydomain' and then load an assembly named 'myassembly.dll' into the domain. The assembly is in the folder "C:\Mydata\assembly", which is not the...
0
by: Michael Kremser | last post by:
Hi NG! I have troubles with loading an application to its own app domain. I have two applications: An caller application named "OfficeTSWCallerDemo" (in a directory like...
3
by: Clarisa | last post by:
Hello Folks I am working on extracting lines of data in a text file based on the string it contains. This is the text file called info.txt:
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

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.