These scripts shows how to do serial communications with a script. Both a VBS and HTA example are included. The VBS sample uses "events" and calls the "com_OnComm" subroutine any time there is received data. The HTA sample does not use events and instead polls regularly using "window.setTimeout". The VBS sample is designed to query a modem or other simple send/receive operation. You enter data and whatever data is received over the next two seconds is displayed. The HTA will display each incoming character as it is received and erase the display each time you send data. The scripts require (and will install) MSCOMM32.OCX and NETCOMM.OCX. The NETCOMM object is used as a "wrapper" for MSCOMM32 because using MSCOMM32 directly from a script requires a developer's license. Rather than attach a fake license in the script (which is easily possible with a little registry code), I elected to use the more legitimate method. For both scripts, the needed MSCOMM32 and NETCOMM controls were embedded in the scripts using the SFX method: http://www.ericphelps.com/scripting/samples/index.htm#Encoding FYI, the registry key needed to fake a license is easy to come by. Look here: 'http://www.yes-tele.com/mscomm.html Microsoft also gave away all license keys with their VB5 license fix program: http://support.microsoft.com/kb/181854 Download the... http://download.microsoft.com/download/vb50pro/utila1/1/win98/en-us/vb5cli.exe ...program, run it, extract the "Vbcmpfix.exe" program, drop that into Notepad, and you'll see the licenses for all the VB5 controls. To use MSCOMM32 directly rather than through the NETCOMM control, refer to this table: ____________________________________________________________ | | MSCOMM32.OCX | NETCOMM.OCX | ---------------|---------------------|---------------------- | CreateObject | "MSCOMMLib.MSComm" | "NETCommOCX.NETComm" | | Input | com.Input | com.InputData | ------------------------------------------------------------ ----------------------------------------------------------------------- All three files contain the same code. Download the most convenient one. Downloading Notes: HTA or VBS FILE IE may try to run the file instead of downloading it! You'll have to right-click and select "Save Link" or "Save Target" to save the file to your hard drive. TXT FILE Be sure to save the downloaded file with a HTA or VBS file extension as appropriate. If your Windows has the default behavior of hiding file extensions, you will have to quote the file name. For example, don't save it as test.vbs, but as "test.vbs". Using quotes forces Windows to honor your file extension. ZIP FILE No problems. The zip file may (or may not) contain other information or directions.