change the background of SEdraft file



I have just start the SolidEdge programming and my first mission is to change the background Template of several drawings...


And my question are :

   What is the best strategy to do that ?

      The Template of a SEdraft file, is it referenced?

if yes is it possible to change the reference ?if no, Do I have to save all the object which define my Template source and create a new sheet then copy these object in the SEDraft file that I want to modify ?   

      There is another strategy?


Thanks a lot for your help


Best regards




Posted by: dd dd
Post date: 7/21/2011 12:47:52 AM


RE: change the background of SEdraft file



no, the background sheets are not referenced. They are normal Sheet objects in the Sheets collection of the background section. To exchange them programmatically you could open your template draft document and the draft document in which you want to replace the background sheets. First make the draft document active and iterate through each background sheet and delete its content by adding everything to the SelectSet and then delete the SelectSet. Now make the template draft active, add everything from the first background sheet to the SelectSet, copy the SelectSet to the clipboard, make the draft document and the corresponding background sheet active and paste the content from the clipboard. Repeat the last steps for all available background sheets.



Posted by: Wolfgang Kunert
Post date: 7/21/2011 8:40:26 PM

RE: change the background of SEdraft file



Super ! Thank a lot for your help.











Posted by: dd dd
Post date: 7/21/2011 9:08:55 PM