ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Upgrading a DOS program that prints labels. (https://www.excelbanter.com/excel-discussion-misc-queries/93305-upgrading-dos-program-prints-labels.html)

Laurence Lombard

Upgrading a DOS program that prints labels.
 
I have a small DOS program written in PASCAL that prints labels on a
tractor feed dot matrix printer that does not work in WinXP anymore. I have
two questions:

1. The program worked perfectly in Win98 but in WinXP it only prints once
the program is closed. The Printing Troubleshooter refers to this issue but
does not provide an solution. Can anyone help.

2. Another option is to convert this program to Excel/VBA. In Pascal I used
the statement writeln(lst... to send data directly to the printer. Is there
a way to do this in VBA. The normal print functions include form feeds which
is not what I want.

Some posters refer to Mailmerge and Word, but I would like to keep things
simple.

Thanks
Laurence



macropod

Upgrading a DOS program that prints labels.
 
Hi Laurence,

There's really no way of knowing from what you've posted what the best way
to handle this might be. All we know is that you've got some data and you
want to print labels from it. Excel, Word, Access may all be suitable, so
too could postscript, PCL, VB, etc, etc. The right tool for the job depends
on what has to be done, who's doing it and what tools they're comfortable
working with.

For starters:
.. what format are the data in - eg a delimited file, stored in a data stream
at the end of your code?
.. what current applications/programming languages are you familiar with, and
do you have any preferences?

Cheers

--
macropod
[MVP - Microsoft Word]


"Laurence Lombard" wrote in message
...
I have a small DOS program written in PASCAL that prints labels on a
tractor feed dot matrix printer that does not work in WinXP anymore. I

have
two questions:

1. The program worked perfectly in Win98 but in WinXP it only prints once
the program is closed. The Printing Troubleshooter refers to this issue

but
does not provide an solution. Can anyone help.

2. Another option is to convert this program to Excel/VBA. In Pascal I

used
the statement writeln(lst... to send data directly to the printer. Is

there
a way to do this in VBA. The normal print functions include form feeds

which
is not what I want.

Some posters refer to Mailmerge and Word, but I would like to keep things
simple.

Thanks
Laurence





Laurence Lombard

Upgrading a DOS program that prints labels.
 
Thank you for your response.

The label data is in Excel and for the DOS program I saved it as a CSV
file. I am most familiar with Excel and VBA and would therefore prefer to
use that to convert the program. If I could find the command to send data
directly to the printer (such as writeln(lst,... in Pascal for DOS) I could
do the rest.

Thanks
Laurence

"macropod" wrote in message
...
Hi Laurence,

There's really no way of knowing from what you've posted what the best way
to handle this might be. All we know is that you've got some data and you
want to print labels from it. Excel, Word, Access may all be suitable, so
too could postscript, PCL, VB, etc, etc. The right tool for the job

depends
on what has to be done, who's doing it and what tools they're comfortable
working with.

For starters:
. what format are the data in - eg a delimited file, stored in a data

stream
at the end of your code?
. what current applications/programming languages are you familiar with,

and
do you have any preferences?

Cheers

--
macropod
[MVP - Microsoft Word]


"Laurence Lombard" wrote in message
...
I have a small DOS program written in PASCAL that prints labels on a
tractor feed dot matrix printer that does not work in WinXP anymore. I

have
two questions:

1. The program worked perfectly in Win98 but in WinXP it only prints

once
the program is closed. The Printing Troubleshooter refers to this issue

but
does not provide an solution. Can anyone help.

2. Another option is to convert this program to Excel/VBA. In Pascal I

used
the statement writeln(lst... to send data directly to the printer. Is

there
a way to do this in VBA. The normal print functions include form feeds

which
is not what I want.

Some posters refer to Mailmerge and Word, but I would like to keep

things
simple.

Thanks
Laurence







Dave Peterson

Upgrading a DOS program that prints labels.
 
Option Explicit
Sub testme01()
Open "LPT1:" For Output As #1
Print #1, "yourstringhere"
Close #1
End Sub

May give you a head start.

Why not write the data to a worksheet and then print that worksheet?

Laurence Lombard wrote:

Thank you for your response.

The label data is in Excel and for the DOS program I saved it as a CSV
file. I am most familiar with Excel and VBA and would therefore prefer to
use that to convert the program. If I could find the command to send data
directly to the printer (such as writeln(lst,... in Pascal for DOS) I could
do the rest.

Thanks
Laurence

"macropod" wrote in message
...
Hi Laurence,

There's really no way of knowing from what you've posted what the best way
to handle this might be. All we know is that you've got some data and you
want to print labels from it. Excel, Word, Access may all be suitable, so
too could postscript, PCL, VB, etc, etc. The right tool for the job

depends
on what has to be done, who's doing it and what tools they're comfortable
working with.

For starters:
. what format are the data in - eg a delimited file, stored in a data

stream
at the end of your code?
. what current applications/programming languages are you familiar with,

and
do you have any preferences?

Cheers

--
macropod
[MVP - Microsoft Word]


"Laurence Lombard" wrote in message
...
I have a small DOS program written in PASCAL that prints labels on a
tractor feed dot matrix printer that does not work in WinXP anymore. I

have
two questions:

1. The program worked perfectly in Win98 but in WinXP it only prints

once
the program is closed. The Printing Troubleshooter refers to this issue

but
does not provide an solution. Can anyone help.

2. Another option is to convert this program to Excel/VBA. In Pascal I

used
the statement writeln(lst... to send data directly to the printer. Is

there
a way to do this in VBA. The normal print functions include form feeds

which
is not what I want.

Some posters refer to Mailmerge and Word, but I would like to keep

things
simple.

Thanks
Laurence





--

Dave Peterson


All times are GMT +1. The time now is 05:09 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com