H
HowPK
How to set the active printer in late binding for word.application using C#?
Try the following, cannot work:
Parameters = new Object[2];
Parameters[0] = printername;
Parameters[1] = 1;
String[] argNames = new String[] { "Printer", "DoNotSetAsSysDefault" };
wordApplication.GetType().InvokeMember("FilePrintSetup",
BindingFlags.InvokeMethod, null, wordApplication, Parameters, null, null,
argNames);
Thanks.
Try the following, cannot work:
Parameters = new Object[2];
Parameters[0] = printername;
Parameters[1] = 1;
String[] argNames = new String[] { "Printer", "DoNotSetAsSysDefault" };
wordApplication.GetType().InvokeMember("FilePrintSetup",
BindingFlags.InvokeMethod, null, wordApplication, Parameters, null, null,
argNames);
Thanks.