Gustav Brock
Gustav at cactus.dk
Tue May 15 03:49:24 CDT 2007
Hi Larry That is not possible just like that. The easiest method is to create a local or shared printer which prints to a port which is (re)directed to the IP address. That will normally require a printer server in front of the printer as these printers typically do not have a built-in printer server. This is probably the setup you have - or you would not wish to print to an IP address ... Another method is to map or redirect one of the old - from DOS - printer ports, LTP1 to LPT3, to the IP address. As these ports are handled like files, you can modify your code this way: Open "LPT2" For Output As #1 /gustav >>> lmrazek at lcm-res.com 14-05-2007 22:47 >>> Hi: Thanks to Gustav, I have some code that works on my local machine ... however, I'll need to print to an IP address, and I haven't been able to find the syntax. This Works: Dim PrtStr As String PrtStr = "Printer Test Text llllllllllllllllllllllllllllllllllll" Open "\\HPLaptop\HPOFFICEJET" For Output As #1 rint #1, PrtStr Close #1 This doesn't (no errors, basically nothing) Dim PrtStr As String PrtStr = "Printer Test Text llllllllllllllllllllllllllllllllllll" Open "10.0.2.22" For Output As #1 Print #1, PrtStr Close #1 Anyone have any ideas? Thanks in advance. Larry Mrazek lmrazek at lcm-res.com