I have a problem when I want to add a library from script. When I add a library using the following script I always get the option "Publish all IEC symbols..." checked, and I do not want this option to be checked.
Even in CoDeSys Help file it says that you should be very cautions when checking this option, so I do not understand why it is checked as default.
Is there a nice way I can avoid this or maybe change the property after adding library? I cannot find such options or objects in the script engine documentation.
proj = projects.primary
for member in proj.get_children():
libman = member
libman.add_library("LibraryA, 0.1 (kk-electronic)")
My current workaround is that I have to export a library manager manually with the desired libraries and I can then import it later using script. To change libraries I can then edit the .export using a text editor.
I have attached demo libraries, scripts, and screendump of publish option, if anyone wants to see exact files.