1. You are viewing our forum as a guest. For full access please Register. WindowsBBS.com is completely free, paid for by advertisers and donations.

Freezing DOS Window

Discussion in 'Other PC Software' started by rturner, 2008/05/28.

  1. 2008/05/28
    rturner

    rturner Inactive Thread Starter

    Joined:
    2008/02/16
    Messages:
    31
    Likes Received:
    0
    Ok, I'll try to keep this as simple as possible.

    I'm working on both a Win2K and WinXP PC's
    with two applications below I will name and give a short description
    - "POSapp" is an application built on Clarion professional developer. (I know you more than likely haven't heard of it) This application was built back in the DOS days and thus runs on DOS or in my case a CMD or DOS window. This is a Point-of-Sale application.
    - "Print Monitor" is an application built on VB6. It watches a source folder (in this case 'C:\invprnt') for any .txt files, when a .txt file is saved to this folder the app then shells a dos command (this actually sends the .txt file to a printer in RAW format - like DOS uses), copies the .txt from source folder to destination folder ('c:\bkupinv') and deletes the .txt out of the source folder.

    Both applications run fine in solitude on either PC, but when both apps are running at the same time, the POSapp freezes. Everything will run fine for about 30 secs then nothing from the POSapp.

    Any suggestions will be appreciated.
    Thank You.
     
  2. 2008/05/28
    mflynn

    mflynn Inactive

    Joined:
    2002/08/14
    Messages:
    4,141
    Likes Received:
    9
    Hi RTurner

    Well this could be a hard one!

    The print monitor is trying to control the Hardware LPT port directly and it will have to fight Windows for it. Windows will win if it is not set up for it!:)

    First I would browse and rt click each program then Click the Compatabiliy Tab and set it as far back as posssible Win95. Put a check in Disable Visual themes and Turn off advance text services.

    If the program has a config for the printer usually LPT1 2 or 3 as the print device then set it to the correct LPT port if you actually have a printer on that port. If you have no printer on an LPT port or setting it to an LPT port does not work then see if the config allows you to set it to print to PRN: (this would be be the default printer). Still may or may not work.

    Next after all above fails. But don't do the below until you try the above first!

    Look here: http://www.dosbox.com/

    Get back with results.

    Mike
     

  3. to hide this advert.

  4. 2008/05/28
    rturner

    rturner Inactive Thread Starter

    Joined:
    2008/02/16
    Messages:
    31
    Likes Received:
    0
    Further explanation

    The POSapp prints to file.

    Print Monitor is built on VB6. DOSPRINTER is installed on the PC. What Print Monitor does is shell a command,
    ( "c:\dosprinter.exe \raw c:\invprnt\File2Print.txt ") is the actual command.

    I have ran these apps on a total fo three PC'c

    MyPC: OS - Win2K SP4
    . CPU - Intel P4 1.8 GHz
    . RAM - 260,848 Kb

    WS01: OS - Win2K SP4
    . CPU - Intel P4 1.8 GHz
    . RAM - 260,080 Kb

    WS02: OS - WinXP SP3
    . CPU - Intel P4 2.4 Ghz
    . MEM - 512 Mb

    Everything works fine on MyPC, but fails on the two WS PC's.
     
  5. 2008/05/28
    mflynn

    mflynn Inactive

    Joined:
    2002/08/14
    Messages:
    4,141
    Likes Received:
    9
    OK look at the
    \windows\systen32\ config.nt
    and
    \windows\systen32\autoexec.nt
    Make all three match the one that works

    on the one that works and add any lines that are missing on the 2 that don't work!

    The below should me in all 3 (but don't bother the one that works). The order below is important!
    In \windows\systen32\autoexec.nt

    lh %SystemRoot%\system32\mscdexnt.exe
    lh %SystemRoot%\system32\dosx


    In \windows\systen32\config.nt
    dos=high,umb
    device=%SYSTEMROOT%\system32\himen.sys
    files=101

    In order to test all of the dos app must be closed and reopened.

    Mike
     
  6. 2008/05/28
    mflynn

    mflynn Inactive

    Joined:
    2002/08/14
    Messages:
    4,141
    Likes Received:
    9
    Are the other 2 printing to My PC via net work share?

    What is the sharename of the printer if so?

    Are there other printers on these other 2 lpt1 ports?

    Mike
     
  7. 2008/05/28
    mflynn

    mflynn Inactive

    Joined:
    2002/08/14
    Messages:
    4,141
    Likes Received:
    9
    Hang in there this time and we will fix this.

    Knowing it all works on one is good to know!

    If it works on 1 it will work on the others.

    Undoubtably has to do with network printing!

    Mike
     
  8. 2008/05/28
    rturner

    rturner Inactive Thread Starter

    Joined:
    2008/02/16
    Messages:
    31
    Likes Received:
    0
    We got busy this afternoon and I haven't had a chance to troubleshoot.
    will be tomorrow.

    It is network printing
    share name is Okiprinter
    attached physically to WS01
    Dosprinter is using the windows default printer to print to, so on all three this is the default printer. On my PC is a laser printer attached physically not shared to either of the WS PC's (this shouldn't be the problem)


    I will post back tomorrow with results.
     
  9. 2008/05/28
    mflynn

    mflynn Inactive

    Joined:
    2002/08/14
    Messages:
    4,141
    Likes Received:
    9
    So it does print accross the network from MyPC to WS01?

    But is your Laser printer attached to an lpt or usb port?

    Is there a printer on the lpt port of the other computer?

    Mike
     
  10. 2008/05/29
    rturner

    rturner Inactive Thread Starter

    Joined:
    2008/02/16
    Messages:
    31
    Likes Received:
    0
    All three match, I did not have to change anything on any PC.

    Laser Printer is attached to USB on 'My PC'
    OkiPrinter is attached to USB on WS01
    --Note: OkiPrint is a Okidata MicroLine 320 Turbo
     
  11. 2008/05/29
    mflynn

    mflynn Inactive

    Joined:
    2002/08/14
    Messages:
    4,141
    Likes Received:
    9
    OK does the printer exist in the printers folder on all computers.

    Just to confirm MyPc can print to the printer on ws01, can ws01 print to the printer (its own local printer)?

    If so then ws02 is the only one that don't print?

    On all three computers paste the below to a command prompt in the order given and one at a time hit enter at end of each line.

    net view > "%USERPROFILE% "\Desktop\netview.txt

    net use >> "%USERPROFILE% "\Desktop\netview.txt

    On the desktop will be a netview.txt file

    Paste them all back to here. So I will know which is which label them or do them in the order MyPC WS01 WS02.

    Mike
     
    Last edited: 2008/05/29
  12. 2008/05/29
    Bilb0

    Bilb0 Inactive

    Joined:
    2007/07/23
    Messages:
    203
    Likes Received:
    6
    This is just a hunch, but you might try setting the POS app to a higher priority in Task Manager (or more appropriately set the print monitor to a lower priority)

    I don't think this is a printer/port/network issue.

    This is going to be an XP issue.

    Has it ever worked on XP and if so, do you know what was changed just before it stopped working?
     
    Last edited: 2008/05/29
  13. 2008/05/30
    rturner

    rturner Inactive Thread Starter

    Joined:
    2008/02/16
    Messages:
    31
    Likes Received:
    0
    netview.txt 'MyPC' - Win2K
    ####################################################
    Server Name Remark
    --------------------------------------------------------------------
    \\IBM1
    The command completed successfully.

    New connections will be remembered.

    Status Local Remote Network

    --------------------------------------------------------------------
    Disconnected T: \\Ibm1\dacpos Microsoft Windows Network <<Now reads \\WS01\dacpos
    Disconnected LPT1 \\ibm1\brotherh Microsoft Windows Network
    The command completed successfully.
    ####################################################

    netview.txt 'WS01' - Win2K
    ####################################################
    Server Name Remark
    --------------------------------------------------------------------
    \\CWSERVER
    \\IBMNETVISTA1
    \\WS01
    \\WS02 WS02
    The command completed successfully.

    New connections will be remembered.

    Status Local Remote Network

    --------------------------------------------------------------------
    OK T: \\Ws01\DacPOS Microsoft Windows Network
    The command completed successfully.
    ####################################################

    netview.txt WS02 - WinXP
    ####################################################
    Server Name Remark
    --------------------------------------------------------------------
    \\CWSERVER
    \\IBMNETVISTA1
    \\WS01
    \\WS02 WS02
    The command completed successfully.

    New connections will be remembered.

    Status Local Remote Network
    --------------------------------------------------------------------
    OK T: \\ibm1\dacpos Microsoft Windows Network <<Now reads \\WS01\dacpos
    The command completed successfully.

    ####################################################

    No, it has never worked correctly on either 'WS02' (XP) or "WS01" (Win2K)

    ---------------------------------------------------
    When the DOS window freezes it does not halt any other operations (e.g. Internet Explorer, Control Panel, or opening another DOS window)
    I can even open another instance of the POSapp and it will run normally until I try to print.
     
    Last edited: 2008/05/30
  14. 2008/05/30
    mflynn

    mflynn Inactive

    Joined:
    2002/08/14
    Messages:
    4,141
    Likes Received:
    9
    OK try this only on WS02

    Cmd prompt
    type (or cut and paste)

    net use lpt1 \\ws01\okiprinter /persistent:yes

    If it is successful in mapping this printer then test by typing in cmd window
    dir >lpt1

    If you get a print out then try the program on this machine.

    Get back with results.

    Mike
     
  15. 2008/05/30
    rturner

    rturner Inactive Thread Starter

    Joined:
    2008/02/16
    Messages:
    31
    Likes Received:
    0
    That seems to have worked.
    The POSapp didn't freeze.
    Thank You very much


    I might post again when I begin testing with multiple PC's running at the same time.
     
  16. 2008/05/30
    mflynn

    mflynn Inactive

    Joined:
    2002/08/14
    Messages:
    4,141
    Likes Received:
    9
    Well?

    How did you handle WS01???

    Mike
     
  17. 2008/06/04
    mflynn

    mflynn Inactive

    Joined:
    2002/08/14
    Messages:
    4,141
    Likes Received:
    9
    Okay dokie!

    Mike
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.