1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

net use lpt1:

Discussion in 'Windows XP' started by virtualgeorg, Aug 16, 2006.

Thread Status:
Not open for further replies.
Advertisement
  1. virtualgeorg

    virtualgeorg Thread Starter

    Joined:
    Sep 9, 2003
    Messages:
    319
    I have a old program that I think is printing from dos and works fine.
    If I want to print to a different computer on the network I have to use
    net use lpt1: \\servername\printername from the command line first, then when I print it goes to that printer on the network instead of the local printer.

    Now if I want print back to the local printer again, how would I use the net use command to send print jobs back to my local printer?

    If I try the net use lpt1: command and enter my local computer name & printer name, that does not work, it still prints to the network printer.

    I have to re-boot to get it to print back to the local printer again.

    thanks
    -George
     
  2. datamonger

    datamonger

    Joined:
    Jul 25, 2006
    Messages:
    244
    Try: net delete lpt1:
     
  3. Cpants

    Cpants

    Joined:
    Aug 16, 2006
    Messages:
    5
    I have a client that I have to capture a printer port for but all of a sudden I can capturer the port but I am not able to print to the device after I capture the LPT1 port. Any ideas would be great.
     
  4. rhynes

    rhynes

    Joined:
    Aug 14, 2006
    Messages:
    901
    can you change the dos software you want to print from to lpt2: or lpt3: cause you can reroute either of those ports too and leave lpt1: alone for local printing.

    first up, in a command prompt, type:
    net use lpt1: /delete /y to get your local port back.

    open notepad and type in the following:
    net use lpt2: /delete /y
    net use lpt3: /delete /y
    net use lpt2: \\computername\printername
    net use lpt3: \\computername\printername

    save it as filename.bat in your startup folder.

    a batch like this will remove the lpts and redo them everytime you boot up the system.
    /y tells dos to delete without prompting.
     
  5. rhynes

    rhynes

    Joined:
    Aug 14, 2006
    Messages:
    901
    BTW, if you can't change the lpt in the dos software and have to print to lpt1, you can create 2 batch files and put them on the desktop.

    batch 1 to connect lpt1: to a network printer

    net use lpt1: \\computername\printer

    batch 2 to remove would be:

    net use lpt1: /delete /y
     
  6. Cpants

    Cpants

    Joined:
    Aug 16, 2006
    Messages:
    5
    What I have now is the following

    Net Use lpt1: /delete /y

    Net Use lpt1: \\servername\printername


    The reason I have server name is because we use thin print. This was all working great until last Friday and cannot figure it out.
     
  7. rhynes

    rhynes

    Joined:
    Aug 14, 2006
    Messages:
    901
    ok, does it work?
     
  8. Cpants

    Cpants

    Joined:
    Aug 16, 2006
    Messages:
    5
    So if I go to a command line and type in the Net Use it will tell me LPT1 is captured to the correct port but nothing prints.
     
  9. rhynes

    rhynes

    Joined:
    Aug 14, 2006
    Messages:
    901
    type into a command prompt:

    net use

    and tell me what it comes back with. There's nothing to worry about security wise as long as the corporate name or something is in there...
     
  10. Sponsor

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Loading...
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/493018