You can give this a try... It creates an external
VB script to send a key.
Sub AnswerQuestion()
Dim fso As FileSystemObject
Dim fsoFile As Variant
Set fso = New FileSystemObject
Set fsoFile = fso.CreateTextFile("C:\Bypass.vbs")
fsoFile.writeline "Set fso = Createobject(""Wscript.shell"")"
fsoFile.writeline "wscript.sleep 1000" 'Adjust time
fsoFile.writeline "fso.sendkeys ""y"", true"
fsoFile.Close
End Sub
Sub test()
Dim wshShell As Variant
'Create Script to answer question
Call AnswerQuestion
'Run the script to answer the Yes No question
Set wshShell = CreateObject("Wscript.Shell")
wshShell.Run ("C:\Bypass.vbs")
MsgBox "Tada", vbYesNo
End Sub
--
HTH...
Jim Thomlinson
" wrote:
I have a certificate on my machine that allows me to download files
from some site. The site (or certificate) requires me to say ok to
client authentication when the window pops up and then my code can
proceed. I want to be able to automate the clicking on the OK in the
client authentication window, any suggestions?
Thanks