We have been successfully using both eDrawings 2009 & 2010 EmodelView.dlls in our delphi batch print program for some time now. With the update to 2011 we are now seeing files opened using the OpenDoc readonly flag being rewritten with the printer output. This is obviously corruptiing our release edrawing files.
We execute in order:
EModelViewControl1.OpenDoc(Dwg,False,False,True,'');
EModelViewControl1.SetPageSetupOptions(Orient,Paper,0,0,1,7,Pbox.Text,0,0,0,0);
EModelViewControl1.Print4(False,Dwg,False,False,False,eScaleToFit,1,1,1,True,0,0);
EModelViewControl1.CloseActiveDoc('');
Dwg, Orient & Paper are variables set with correct options
Pbox.Text is the value stored in a dropdown box listing available printers configured on the host system.
Referring to the eDrawings API Help @ http://help.solidworks.com/2011/English/api/SWHelp_List.html?id=5f69438873aa43228cf7c79aef5f1c9e#Pg0 I can see nothing incorrect with our configuration but we see our opened EDRW rewritten with the output which is supposed to be sent to the printer.
Any assistance would be appreciated.
SolidworksApi macros