How to share a Color Palette to a Library file?

How to share a Color Palette to a Library file?

clairekruppGhafari
Observer Observer
24 Views
4 Replies
Message 1 of 5

How to share a Color Palette to a Library file?

clairekruppGhafari
Observer
Observer

[ FlexSim 21.2.2 ]

I have created a standard Color Palette that I want to copy to other models and share with my colleagues.

It does not seem to have an "add to Library" button like other elements do, and I can only duplicate it inside the same model.

Is there a way to copy it to another model?

Thanks!

0 Likes
Accepted solutions (1)
25 Views
4 Replies
Replies (4)
Message 2 of 5

Matthew_Gillespie
Autodesk
Autodesk
Accepted solution

You can use applicationcommand("addtouserlibrary") in a script window to add the palette to a user library.

applicationcommand("addtouserlibrary", <object>, <rankOfUserLibrary>, <autoInstall>);

This will add the color palette to the first loaded user library:

applicationcommand("addtouserlibrary", Model.find("Tools/ColorPalettes/ColorPalette1"), 1, 0);


Matthew Gillespie
FlexSim Software Developer

0 Likes
Message 3 of 5

clairekruppGhafari
Observer
Observer
Thanks @Matthew Gillespie . So it sounds like I have to create at least one user library first?
0 Likes
Message 4 of 5

Matthew_Gillespie
Autodesk
Autodesk

Yes. Or you can also create a user library through code.

applicationcommand("newuserlibrary")


Matthew Gillespie
FlexSim Software Developer

0 Likes
Message 5 of 5

clairekruppGhafari
Observer
Observer
Thanks!
0 Likes