
use of automation object methods with optional arguments
use of automation object methods with optional argumentsJScript will only let you omit optional arguments at the end of the argument list. You're stuck with specifying whatever the default values are for those that precede the one you want (or use VBScript instead ;-).
--
Michael Harris
MVP - Windows Script
hi,
I'm trying to use the PrintOut() method exposed by the Word.Application.Document object. It works fine when no parameters are passed (as in i can print word documents to the printer)..but if u check the object browser of Word then u can see that it can take optional arguments one of which is PrintToFile...now i've been trying to use this to print a word document to file but have been unsuccessful..how do i specify optional arguments when i call the PrintOut funtion..I'm using Windows Host Scripting with JScript ..there are many other optional arguments that can be passed but how do specify only the one i want(in this case the PrintToFile argument)
thanx