Community
Fusion API and Scripts
Got a new add-in to share? Need something specialized to be scripted? Ask questions or share what you’ve discovered with the community.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

API accessible face properties

1 REPLY 1
SOLVED
Reply
Message 1 of 2
jeremy.herbert
511 Views, 1 Reply

API accessible face properties

Hi,

 

I'm looking for a way to add a property/note to a face (just a text string like "ABCDEF1234") through the normal user interface somehow, but also have it accessible via API. I don't want to add it to a whole body, I need to be able to control it on a per-face basis. Is there a creative way of doing this? I'd love to be able to add a physical material on a per-face basis, but I can understand why that isn't allowed.

 

I currently was thinking of just making a custom appearance with the name of the appearance being the property, but it seems that the custom library support doesn't work the way I think it does. I asked about that separately here: http://forums.autodesk.com/t5/design-validate-document/custom-appearance-library-issues/m-p/6710580#...

 

As an aside, it would be nice if you could add a text comment to an appearance. Something like "This is the powder coat colour of the current prototype parts as tested on machine XYZ by ABC, calibration serial number 1234567890." belongs with the appearance I think, not with the physical material.

 

Thanks,

Jeremy

1 REPLY 1
Message 2 of 2

Solved this one myself actually. I wrote a python addin which lets me select an entity view and edit Attributes (as in the class) associated with it. I can even write JSON and the python code will validate it; very neat! I can then pull this info out of the entity later via a script.

 

I'm a much bigger fan of this ecosystem than the programming interface in Inventor. Dealing with win32com/python and Inventor was a real pain, but this is super easy. (Although my issues may have been related to the win32com part, not the Inventor part...)

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