Custom property value appearing in other models!

Custom property value appearing in other models!

Anonymous
Not applicable
345 Views
1 Reply
Message 1 of 2

Custom property value appearing in other models!

Anonymous
Not applicable

Using VBA I've created a module and I use ......("Inventor User Defined Properties").Add("RevDate") and set a value. This can be changed by the user but needs to be remembered for that model. This value is also found and used in the drawing for that model using illogic

Try

oDate = iProperties.Value("Custom", "RevDate")

Catch

oDate = DateTime.Now.ToString("d")

End Try

And then oDate is used.

 

Now I've added the iLogic I have a problem. After setting a RevDate for a model, if I open a fresh template to create a new model the date set in the previous model comes up as the RevDate, even though that property should have only just been created and not set to anything!

 

What have I done wrong!?

0 Likes
346 Views
1 Reply
Reply (1)
Message 2 of 2

sgwilliams
Collaborator
Collaborator

The Template has to be opened as a template and not as a new file from the template. Once you have it open you can remove the date that is set and save. Then create a new model and the date should not be set now. Hope this helps!

Work Station : Custom built, Liquid Cooled, Asus Pro WS X570-ACE Motherboard; AMD Ryzen 9 3900X 3.8 GHz 12-Core Processor; ASUS TUF Gaming NVIDIA GeForce RTX 3060 V2 OC Edition Video Card; 32 GB CORSAIR Dominator Platinum DDR4-2132 Memory ; Samsung 850 EVO 1TB SSD Drive.
0 Likes