pparker061097
asked on
Network Printer object via REXX
I need to bypass the W95 lack of cooperation with the WPS. If it's possible to create a Network Printer object with a REXX program, how do I go about doing it? Please be explicit: I have some knowledge of REXX programming, but almost no experience using it to create WPS objects.
There is an LJ4Si hung off a W95 box on the Peer LAN. I can use it via a command line call (net use lpt1 \\serv2\hplj) but I cannot get the Network Printer template to see this printer. I am a bit familiar with using Rexx's SysCreateObject. What I do not know, nor know where to find (not being a developer), are the precise parameters etc. that must be used with SysCreateObject to create a Network Printer object, either directly on the WPS desktop or in a subfolder thereof. I currently have an LJ4Si object installed on LPT1. Together with the net use command above, this enables me to print on the LJ4Si hung off the W95 box by drag-and-drop (e.g.). Before the other box was "upgraded" to W95, it was a WfWG box and I had a Network Printer object for this same printer. I'd like to get it back, in some way, if possible.
There is an LJ4Si hung off a W95 box on the Peer LAN. I can use it via a command line call (net use lpt1 \\serv2\hplj) but I cannot get the Network Printer template to see this printer. I am a bit familiar with using Rexx's SysCreateObject. What I do not know, nor know where to find (not being a developer), are the precise parameters etc. that must be used with SysCreateObject to create a Network Printer object, either directly on the WPS desktop or in a subfolder thereof. I currently have an LJ4Si object installed on LPT1. Together with the net use command above, this enables me to print on the LJ4Si hung off the W95 box by drag-and-drop (e.g.). Before the other box was "upgraded" to W95, it was a WfWG box and I had a Network Printer object for this same printer. I'd like to get it back, in some way, if possible.
ASKER
Adjusted points to 100
ASKER
Edited text of question
The problem is probably that the Network Printer Object only communicates with a Printer Queue on a OS/2 Server. A normal printer object doesn't. (There are two templates for a printer)
What you can do is create a normal printer object. The driver is clever enough to include laserjet coding when printing to a non-OS/2 printer server (or should be).
I can't help you with the statements for the SysCreateObject. I haven't tried this and don't have time to experiment. You could use a package like 'DeskMan/2' (I think that's the one) which can read an object's properties.
I'm sorry, I don't think I can help you. At least the question is a lot clearer now.
What you can do is create a normal printer object. The driver is clever enough to include laserjet coding when printing to a non-OS/2 printer server (or should be).
I can't help you with the statements for the SysCreateObject. I haven't tried this and don't have time to experiment. You could use a package like 'DeskMan/2' (I think that's the one) which can read an object's properties.
I'm sorry, I don't think I can help you. At least the question is a lot clearer now.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
For OS/2 you can call SysCreateObject. (I can be more explicit if you want to). I'll have to look it up though (I wrote a 'C' program that manipulates objects from a response file, so the Rexx way is a bit rusty).
Creating a network printer object is not as easy as creating a regular object. I haven't tried this with Rexx, but I know that a device driver must be installed locally and communications with the network printer could be necessary. We create a shadow from one of the LSA folders (Network).