M
Michael Kelly
I'd like to be able to send a keystroke to my browser (in particular
^F). Is there a way for javascript to interract with the browser in
this fashion. I know VBScript has a SendKeys method but I'd prefer to
use JavaScript whenever possible.
In addition I wish to determine the users default printer so I can
have the app server print a document to the printer (the page is
in-house and the users printer will be on the network). I was able to
determine the printer using VBScript (I am getting far more familiar
with this language than I would have preferred) thusly:
<SCRIPT TYPE="text/vbscript" LANGUAGE=VBScript>
Function CensusForm_OnSubmit()
Set lShell = CreateObject( "WScript.Shell" )
lPath = "HKCU\Software\Microsoft\Windows
NT\CurrentVersion\Windows\Device"
lPrnInfo = lShell.RegRead( lPath )
Document.CensusForm.PrinterInfo.Value = lPrnInfo
CensusForm_OnSubmit = True
Alert "Print job sent to server!"
end Function
</SCRIPT>
^F). Is there a way for javascript to interract with the browser in
this fashion. I know VBScript has a SendKeys method but I'd prefer to
use JavaScript whenever possible.
In addition I wish to determine the users default printer so I can
have the app server print a document to the printer (the page is
in-house and the users printer will be on the network). I was able to
determine the printer using VBScript (I am getting far more familiar
with this language than I would have preferred) thusly:
<SCRIPT TYPE="text/vbscript" LANGUAGE=VBScript>
Function CensusForm_OnSubmit()
Set lShell = CreateObject( "WScript.Shell" )
lPath = "HKCU\Software\Microsoft\Windows
NT\CurrentVersion\Windows\Device"
lPrnInfo = lShell.RegRead( lPath )
Document.CensusForm.PrinterInfo.Value = lPrnInfo
CensusForm_OnSubmit = True
Alert "Print job sent to server!"
end Function
</SCRIPT>