Solved

I need a sounding board to help me think through a DOS printing problem

Posted on 2015-01-13
24
326 Views
Last Modified: 2015-01-26
I have a customer that has just gotten a new Sharp copier. Before it arrived we were told it would print to DOS. The copier was installed in Windows7-XPMode, shared, and a batch file with a net use statement was run to create an LPT port.  I have been using this formula to print to copiers and laser printers for years. This copier will print from a cmd prompt to the copier so in my mind it will print to DOS. Examples DIR > lpt2 will print to the copier without a form feed, it also works using the PRINT command to send a text file to the copier without a form feed command. Where it doesn't work is within Q&A which has its own printer drivers. I have used a HP LaserJet 4 driver in Q&A for years to print to a wide variety of machines. Am I correct that the copier is indeed DOS compatible because of what it will print and just not Q&A compatible because of what it won't print?
0
Comment
Question by:jbcbussoft
  • 12
  • 7
  • 3
  • +2
24 Comments
 
LVL 33

Accepted Solution

by:
paulmacd earned 167 total points
Comment Utility
"DOS Compatible" doesn't apply here.  You're sending ASCII data to the printer, and it's putting it on paper - nothing more, nothing less.

For formatting - knowing when page breaks happen, manipulating margins, etc - software needs to understand the capabilities of the printer.  Windows does this for all programs via drivers.   Back in the DOS days, each program was written to work with certain printers.  When your software no longer supported available printers, you had to upgrade or replace.

It's possible this Sharp copier can be put into some sort of compatibility mode -  What are we talking about here?  PCL3? - and that may solve your problem.  It's also possible the software knows how to write to a text file, and you can come up with some process to print that text file under Windows, sidestepping the problem altogether.  

Lastly, if the industry that uses this software is so beholden to it that it's still using it 30 years later, it might be worth hiring some programmers to recreate it in a modern language and sell that back to your customer.
0
 
LVL 47

Assisted Solution

by:dbrunton
dbrunton earned 167 total points
Comment Utility
>>  Before it arrived we were told it would print to DOS. The copier was installed in Windows7-XPMode, shared, and a batch file with a net use statement was run to create an LPT port.  

I think you mean it will print text from DOS applications.  What are the contents of the batch file?  You can't use LPT1 unless you have an administrator account.  LPT2 is OK.

>> Where it doesn't work is within Q&A which has its own printer drivers. I have used a HP LaserJet 4 driver in Q&A for years to print to a wide variety of machines. Am I correct that the copier is indeed DOS compatible because of what it will print and just not Q&A compatible because of what it won't print?

Now what is Q&A?  A DOS or Windows application.  If it is a DOS application you may be able to select the port - LPT2 - to direct text output to.
0
 

Author Comment

by:jbcbussoft
Comment Utility
paulmacd - I don't know about compatibility mode. The copier services Win7 and Q&A which is a DOS program. I'm not onsite I will have to check but I think PCL5 is the lowest drivers we have. A new database is being developed.

dbrunton - I am using LPT2 for the copier.
Net use lpt2 \\computername\sharename /persistent:yes

Q&A is a database program that was developed in the 1980's and was available for retail/wholesale purchase until about 2000-2001. It prints formatted text in the manner you choose. It also had a word processor that would print a variety of font selections in the size that is selected using the print drivers that could be installed.
0
 
LVL 47

Expert Comment

by:dbrunton
Comment Utility
So is this version of Q&A DOS or Windows?  If Windows which version 16 bit or 32 bit?

And how are you running it under Windows 7?

If you are running it in an emulator and it is pure DOS based then investigate VDos http://sourceforge.net/projects/vdos/  Allows printing to Windows printers.
0
 

Author Comment

by:jbcbussoft
Comment Utility
Q&A DOS 4.0 ca 1993 16bit
XPMode
0
 
LVL 47

Expert Comment

by:dbrunton
Comment Utility
At this stage I'd say the copier is DOS compatible if printing from inside XP mode does what you say in the question.  But let's test.

I'd install the SemWare® Editor Junior (TSE Jr) http://www.semware.com/  Just the Shareware DOS version.  This is 16 bit.  Install it in XP mode and type some text and see if it prints.

I'm away for about six hours.
0
 

Author Comment

by:jbcbussoft
Comment Utility
I can't get to the systems for about 16 hours.
0
 
LVL 47

Expert Comment

by:dbrunton
Comment Utility
Suggestions only.

Check that Q&A is set to print to LPT2.
And test the DOS functionality by using the Semware Editor as I suggest above.  Again check that Semware is set to print to LPT2.
0
 
LVL 38

Assisted Solution

by:Herman D'Hondt
Herman D'Hondt earned 166 total points
Comment Utility
Another way to check DOS/PCL5 compatibility is to send a text file to the printer. Open a DOS prompt, take any text file and use the command:

COPY file.txt LPT1:

Alternatively, type:

COPY CON LPT1:
then type any text (multiple lines if desired) and terminate it with a Ctrl-Z (DOS End-Of-File)

If you want to test PCL compatibility, you can insert some PCL5 commands in the text. If you want to do that, to type the Esc character in a CMD window, type Ctrl-[
0
 

Author Comment

by:jbcbussoft
Comment Utility
dbrunton - I installed vdos and set it up to start the program. It ran well and printed to the copier but only while I was logged in as the domain admin. When I logged in as a standard user I got an error and the program would not start. I have not tried the other suggestions yet.
0
 
LVL 47

Expert Comment

by:dbrunton
Comment Utility
installed Vdos on xp mode or windows 7 itself?

It will work in Windows 7.
0
 
LVL 38

Expert Comment

by:Herman D'Hondt
Comment Utility
When I logged in as a standard user I got an error
Try logging in as a standard user and running the program as administrator, by right-clicking it and selecting "Run as administrator". If that works, then you need to change the permissions on it.
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 

Author Comment

by:jbcbussoft
Comment Utility
Windows 7.
0
 

Author Comment

by:jbcbussoft
Comment Utility
I did that and it worked. I gave the user blanket permission on the vdos folder and all the program files on the server.
0
 
LVL 47

Expert Comment

by:dbrunton
Comment Utility
Check Q&A is using LPT2.

Also have a read of this thread http://sourceforge.net/p/vdos/discussion/general/thread/98b18428/  Not sure if anything is relevant there but may be of use.

Note they discuss using DOSBox and Megabuild but you should NOT have to go that way.  Megabuild is slightly obsolete (although I do use it for its networking myself).
0
 

Author Comment

by:jbcbussoft
Comment Utility
I'm not talking about a printing error. Q&A would not run through vdos while I was logged into windows 7 with a standard user.
0
 
LVL 38

Expert Comment

by:Herman D'Hondt
Comment Utility
I've been going through the original question again, and have a couple of questions.

DIR > lpt2 will print
That implies the printer is connected via (logical port) LPT2. What port does Q&A use? Can you change the port assignment to LPT1? Does it then work?

Where it doesn't work is within Q&A
What actually happens when you try? Does the printer do anything at all (even blinking lights, etc)? Any error messages on either the printer or the PC?
0
 

Author Comment

by:jbcbussoft
Comment Utility
hdhondt - most of the users have 2 printer options for Q&A. First a laser that is connected to their computer or a networked printer close by, second is the copier. All of the lasers print to lpt1. Some of them are usb, some are usb to lpt, and some are networked. All of them use a variation of the net use statement in a batch file. The copiers have been networked and have been made available to Q&A using a net use statement in a batch file.

The copier will print to the copier in xpmode at a cmd prompt, but through Q&A it flashes a waiting message and does nothing else.
0
 
LVL 41

Expert Comment

by:Jackie Man
Comment Utility
0
 
LVL 47

Expert Comment

by:dbrunton
Comment Utility
Vdos IS Dosbox.

It has just been modified to be a DOS applications emulator rather than a DOS games emulator.  Printing has been added for example.  Dosbox did not support that (the official Dosbox version did not, unofficial versions did).
0
 

Author Comment

by:jbcbussoft
Comment Utility
"Have you tried Dosbox to run QA4?"

This is from the website

"vDos derived from the DOSBox project (http://sourceforge.net/projects/dosbox/).

DOSBox is targeted at gaming and available for many operating systems.
If you consider using it for a database application. DON’T, mostly you’ll end up with corrupted data.


vDos is for serious (mainly text mode) DOS applications, Windows 32/64 bits (XP and later) only.
It lacks many of the hardware emulations of DOSBox (no joysticks, basic VGA...).
Instead it adds a live file system, file/record locking, Windows printing, a scalable screen font and more.
You should be able to run your DOS application quickly in a safe and convenient way."
0
 

Author Comment

by:jbcbussoft
Comment Utility
I have spent way to much time on this lately but I keep learning. Q&A doesn't seem to 'like' LPT2 anymore. This apparently occurred after the domain/AD changes. Before this I was able to print to LPT2. The batch file that controls the port capturing was changed for the copier to LPT1 and the copier printed. I haven't thought of a work around yet.
0
 

Author Comment

by:jbcbussoft
Comment Utility
I now have lpt2 and lpt1 printing from the DOS application. The problem was on my end. I had a batch file set to one port but the DOS printer in the printer folder setup with the wrong lpt. Thanks for the suggestions.
0
 

Author Closing Comment

by:jbcbussoft
Comment Utility
Thanks for the help. I found my problem and fixed it. Everybody who replied was given points.
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Ok I have been working on this for some time having learned and gained certification in XenDesktop 4 along came version 5 which was released last month. Since then I have been working to deploy XenDesktop 5 in a small environment with only 2 virt…
Today, still in the boom of Apple, PC's and products, nearly 50% of the computer users use Windows as graphical operating systems. If you are among those users who love windows, but are grappling to keep the system's hard drive optimized, then you s…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now