Community
Inventor Programming - iLogic, Macros, AddIns & Apprentice
Inventor iLogic, Macros, AddIns & Apprentice Forum. Share your knowledge, ask questions, and explore popular Inventor topics related to programming, creating add-ins, macros, working with the API or creating iLogic tools.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

iLogic to set appearance from iproperty

4 REPLIES 4
Reply
Message 1 of 5
cbn56B4Z
651 Views, 4 Replies

iLogic to set appearance from iproperty

i want to have the material surface treatment in the titleblock of the drawings and for this surface to also show in 3D.

so i have made a little appearance library with them all.

but now i need to figure out an easy solution to set them all.

i could one by one go into every part and write in a custom iProperty the definition and manually change the appearance at a part level (if i just change the appearance in the assembly the part still uses the generic appearance)

 

here is my initial idea of how some might try and solve it.

Assembly: (to set parts treatment)

Pop-up textbox with options and then

Try to set a custom iProperty of underlying part

If success then set appearance in at the part level

If fail just change appearance in assembly (this is for library parts that don't allow for editing)

 

Part: (get parts treatment whenever i save)

check if iProperty has been filled out

set appearance according to what is filled in the iProperty

 

Part: (to set parts treatment)

Pop-up textbox with options and set iProperty

Get appearance from custom iProperty

 

i've done quite a lot of extensive googling but every code setting the appearance through an assembly doesn't do it at the part level so when i open the part it's still the untextured grey default appearance

Labels (2)
4 REPLIES 4
Message 2 of 5
cbn56B4Z
in reply to: cbn56B4Z

thinking about it my first solution is way too convoluted than it needs to be.

i could just fill out the treatment in the BOM of my top assembly and then have an iLogic that pulls from the custom iProperties and updates the parts appearances accordingly. that seems like the simplest solutions, but i still somehow need to update the appearance based on iProperties at a ipt level from an assembly...

Message 3 of 5
chandra.shekar.g
in reply to: cbn56B4Z

@cbn56B4Z,

 

Please provide non confidential sample assembly with parts (custom iProperty) to investigate.

 

Thanks and regards,


CHANDRA SHEKAR G
Developer Advocate
Autodesk Developer Network



Message 4 of 5
WCrihfield
in reply to: cbn56B4Z

I can understand that you would want the current Appearance data written to a Custom iProperty within the parts, if you are wanting that information to be shown in the Title Block of those parts drawings.  But why would you want to Set the appearance of a part based on a Custom iProperty, instead of just setting it from your appearance library directly?  What information would you want to push from an assembly file to its parts?  Are you planning on dictating the part appearances, based on how you want them to look within the assembly?  If so, are any of those same parts also used in any other assemblies that might need their appearances set differently.  Why not just create multiple Design View Representations within the parts (one for each needed appearance difference), then within the assembly choose which representation you want it to use?

Wesley Crihfield

EESignature

(Not an Autodesk Employee)

Message 5 of 5
cbn56B4Z
in reply to: WCrihfield

the reason for all the different iproperties is that i already have an ilogic form that spits out a material report. but it all just looks like the generic untreated metal unless i go in and manually change the appearance in the BOM too. while it would seem pretty simple (if possible) to just have a logic that sets the appearance in the BOM based on the options ticked. see image for clarification.

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

Post to forums  

Technology Administrators


Autodesk Design & Make Report