I have a strange bahaviour when I use axlRunBatchDBProgram("artwork"....
To make sure I get the correct output names I try to remove ARTWORK_PREFIX and ARTWORK_SUFFIX variables before running the batch command, see code below. The problem is that if I have a design that have a prefix stored when I open the design, then this prefix is still included in the output name when I run the batch command. HOWEVER - if I check the prefix in the graphical environment (menu Export->Gerber Parameters) the prefix is empty after running the script. Also - if i generate the corresponding output from the graphical environment there is no prefix attached to the name.
If I then run the script again the prefix is still attached to the output name!
Is there some other variable that is used when running the batch command or what is the deal?
code for artwork generation:
axlDBDeleteProp( nil "ARTWORK_PREFIX") axlDBDeleteProp( nil "ARTWORK_SUFFIX") filmlayers = axlGetParam("artwork")->groupMembers ;Create list with the output films foreach(s_film filmlayers axlRunBatchDBProgram("artwork" strcat("artwork -f " s_film " " axlCurrentDesign(), ".brd"), ?noUnload t ?logfile "photoplot.log" , ?warnProgram t) system( strcat( "move .\\Output\\" s_film ".art " s_rel_outdir "\\" s_filename "_" s_film ".art")))
You would need to save the design before running axlRunBatchDBProgram for that to work. Why not just run axlFilmCreate?
Is not axlFilmCreate just to create the films? In this case I want to generate the gerber files.
Anyway - it now works after saving the design.