Can I hide a dialog opened with sendkeys
Hi frends.I have a problem, trying to set the printer driver options back to default,I have looked every were, but could not find any thing.
It seems the only way is using sendkeys.
Me problem now, is that the fileprintersetup properties is visible, will the sendkey strig is running.
Could some one please help me hide it.
I'm doing like this.
Sub NulstilPrinter()
pr = ActivePrinter
Select Case True
'pr12 to 15 is predefind printernames
Case CP(pr, pr12), CP(pr, pr13), CP(pr, pr14), CP(pr, pr15)
'^%n opens the fileprintersetup dialogbox, %i opens fileprintersetup properties, from there i go around in the driver setting the different options back to default
SendKeys "^%n %i d %r %n %r +{TAB} {RIGHT} %r {ENTER} +{TAB}
{RIGHT} %r %s %r {ENTER} {RIGHT} %r {RIGHT} %r {ENTER} {esc}"
Case Else
MsgBox ("Du har ikke valgt en Canon printer!")
End Select
End Sub
Mik Agergaard
