.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to set cuiFileVersion?

0 REPLIES 0
Reply
Message 1 of 1
Anonymous
310 Views, 0 Replies

How to set cuiFileVersion?

Hello everybody,
I will explain case the short story.
This is for Acad 2007,08 and most probably 09.
I`ve managed to class that creates a toolbar with buttons and icons based on a list of all methods in the same .dll that are tagged with [CommandMethod()] tag, but there is a minor problem. The .dll is loaded on startup, because I have installed it in the regisrty. On startup I want to check if the already loaded CUI in Acad was generated by an earlier version of the .dll or the CUI is generated from the now-loading .dll
The whole idea is that the upgrade of the program is just a copy-paste-overwrite the .dll in the ACAD folder and then the CUI building script will rebuild it during the next startup adding the new buttons and icons in it. In that way there will be no need of installer. Just a copy-paste. No need of administrator privileges to install the .dll, no need to write in the registry after installation, no need of user maintenance.
But in order to rebuild the CUI I have to find out that the current loaded in Acad CUI is outdated. I saw the public class (inside Customisation Section) cuiFileVerion (or just FileVersion class), but I did not find any way to modify it during construction of the CUI, because its properties are set as read only and it has no constructor in which I can pass version parameters. I don`t even see any constructor in the metadata. After the construction of my new CUI it does have FileVersion, but it is set automatically.
Do you know the way of setting the major, minor or user versions of the cuiFileVersion? Any other reasonable solution will be great! I know that I can always count the number of the methods of the current loaded in ACAD CUI and these in the .dll that is loading and compare the counts, but if they are the same count and the update is just a bug-fix I will not be able to do it that way. Other solution is to make my own tag like [CommandMethod] - [MyCustomCuiVersion], but this information will not be added to the cui. My question is "How can I distinguish between 2 different verions of 2 CUIs that have the same name? (How to destinguish between the versions?)"
I have read the arxdev.chm and acad_dev.chm and acad_mgd.chm, but everywhere these properties are described as read only and I have searched http://through-the-interface.typepad.com/ with no success. Edited by: ognyandim on Dec 18, 2009 9:29 AM
0 REPLIES 0

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost