>Hi
>
>In our company, we are using Dos Base application Foxpro 2.6a, it is running very fine and meets all the requirements as per management. The thing is we are not getting print on remote side, like we have a work station in warehouse which is connected to the server in head office though VPN and we are doing RDP. I tried all possible ways but not got through. If somebody help me how to solve this! Please note that the window base application is under development stage and will take some months to implement.
As an example, suppose that:
- your FoxPro DOS 2.6a application prints to printer port LPT1
- the server's name is "Server1"
- your warehouse computer has an attached printer that is an HP LaserJet 4. You want print jobs to be printed on this printer
What you can do is:
1. Install the HP LaserJet 4 printer driver on the server computer. It does not matter that there is no HPLJ4 printer directly attached to the server, just select LPT1 as the port on which the printer is "installed".
2. Go into the Sharing properties of that installed printer, and make it shared. Give it a printer share name, for example "HPLJ4".
3. Create a small CMD or BAT file, in a drive/folder that is accessible by the RDP user(s). Contents of this file:
@ECHO OFF
REM RemoteDOSPrint.CMD
REM First, remove any existing LPT1 printer port redirection:
NET USE LPT1 /DEL
REM Now, redirect DOS printer port LPT1 to the local shared printer on the server:
NET USE LPT1 \\Server1\HPLJ4
REM If you'd like this redirection to persist across logons, you can add /persistent:y to the end
REM End of CMD file
4. As you probably already know, for remote printing to work as expected with RDP, on the warehouse machine you must select the HP LaserJet 4 printer as the default printer before you start your RDP session.
5. Start the RDP session.
6. In the RDP session, run the RemoteDOSPrint.CMD batch file you created above.
7. Now, start and run your FoxPro DOS 2.6a app. Any print jobs the application sends to the DOS LPT1 port should now be redirected as follows:
Server DOS LPT1 port --> "HPLJ4" print queue on server (via local printer port redirection) --> HP LaserJet 4 print queue and printer on workstation (via RDP printer redirection)
Regards. Al
"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov
Neither a despot, nor a doormat, be
Every app wants to be a database app when it grows up