Editdocument method "optional" parameter

I don’t know if it’s just me, but after getting kicked out of Notes about 5 times with first an Object Variable Not Set error and then an NSD error, I changed this line of code:

Call workspace.EditDocument(newDoc)

to

Call workspace.EditDocument(True, newDoc)

After adding in the optional True parameter, it works.

Subject: Editdocument method “optional” parameter

I think it’s optional in that you don’t have to provide a value, even if you do have to have a placeholder there. Just for fun, try this:

Call workspace.EditDocument( , newDoc)

Subject: RE: Editdocument method “optional” parameter

Ah - got it. Since it was giving me an NSD error, I couldn’t run it through debugger to see exactly what was causing the Object Variable Not Set error. That’s it. Thanks.