any unique property for differentiate inventor files?

any unique property for differentiate inventor files?

Anonymous
Not applicable
877 Views
3 Replies
Message 1 of 4

any unique property for differentiate inventor files?

Anonymous
Not applicable

hey, devs

do Autodesk Inventor files especially .iam assembly files have a unique property (something like an internal name, ID or Guid) that can differentiate them from each other even when they have the same name?

I am thinking of their full path by the time, but i am curious that is there any other way or not?

actually, i have an add-in that i need to store some data in it while running, that these data are related to each document naturally, i would like to differentiate these data for each document using a unique value.

0 Likes
Accepted solutions (2)
878 Views
3 Replies
Replies (3)
Message 2 of 4

JamieVJohnson2
Collaborator
Collaborator
Accepted solution

Document has RevisionID, and DatabaseRevisionID, both create GUID, which means they are unique values.

Jamie Johnson : Owner / Sisu Lissom, LLC https://sisulissom.com/
0 Likes
Message 3 of 4

pball
Mentor
Mentor
Accepted solution

Like the previous poster said yes there are unique ids per file. Below is a thread that discusses this topic further and has some examples.

 

https://forums.autodesk.com/t5/inventor-forum/need-to-catch-my-students-cheating/td-p/5587748/page/2

 

The other option could be to use secret iProperties, this would allow you to store hidden info inside a file. I personally haven't used them but they are apparently only accessible from the API. Below is what I saved from a post years ago.

 

Dim secretPropSet As Inventor.PropertySet = mDocument.PropertySets.Add("Secret Property Set")
Dim secretProp As Inventor.Property = secretPropSet.Add("ABC-XYZ", "Secret Property")
Check out my style edits for the Autodesk forums
pball's Autodesk Forum Style
0 Likes
Message 4 of 4

Anonymous
Not applicable

thank you @pball 

that was a pretty helpful way of storing some data in the file itself, 

that was very interesting and answered a lot of my questions in mind.

0 Likes