PC Review


Reply
Thread Tools Rate Thread

can a file be sent to the printer?

 
 
Talal Itani
Guest
Posts: n/a
 
      18th Apr 2007

Is there a way to send a file to the printer, without opening the
application that generated the file? I tried to print to a file, from the
application, then drag that file to the printer, but this did not work. Is
there a way? Thank you.


 
Reply With Quote
 
 
 
 
Pegasus \(MVP\)
Guest
Posts: n/a
 
      18th Apr 2007

"Talal Itani" <(E-Mail Removed)> wrote in message
news:bxgVh.6073$0S1.1960@trnddc01...
>
> Is there a way to send a file to the printer, without opening the
> application that generated the file? I tried to print to a file, from the
> application, then drag that file to the printer, but this did not work.

Is
> there a way? Thank you.
>


With some printers the following method works:
1. Share the printer as MyPrinter (for example).
2. Click Start / Run / cmd {OK}.
3. Type this command:
net use LPT2: "\\%ComputerName%\MyPrinter"
4. Type this command:
copy /b c:\Print.prn LPT2:
where c:\Print.prn is your print file.



 
Reply With Quote
 
Jim in Canada
Guest
Posts: n/a
 
      18th Apr 2007
Right click
Print

"Talal Itani" <(E-Mail Removed)> wrote in message
news:bxgVh.6073$0S1.1960@trnddc01...
>
> Is there a way to send a file to the printer, without opening the
> application that generated the file? I tried to print to a file, from the
> application, then drag that file to the printer, but this did not work.
> Is there a way? Thank you.
>



 
Reply With Quote
 
Talal Itani
Guest
Posts: n/a
 
      18th Apr 2007

"Jim in Canada" <warnerjim@*removethis*shaw.ca> wrote in message
news:_YgVh.90010$aG1.69519@pd7urf3no...
> Right click
> Print


When I right click, there is no print option.


 
Reply With Quote
 
Chuck
Guest
Posts: n/a
 
      18th Apr 2007
"can a file be sent to the printer?"

Yes there is a way--if the file is printer compatable, and you use a script(batch) file, or from a command line.
You will likely be sending the file to Lpt1.
copy /b source.prn Lpt1 is a common simple usage for printing files produced by an application when the application output is sent to a file as printer ready.

(Source.txt should also work for ascii text files)

"Drag and drop printing" may also work for your task. do a web search for it.

The copy command can be used by typing CMD in the Start Run box.
Then type it in from the command line prompt in the "Dos" window.

Copy
Copies one or more files from one location to another.

Syntax
copy [/d] [/v] [/n] [{/y|/-y}] [/z] [{/a|/b}] Source [{/a|/b}] [+ Source [{/a|/b}] [+ ...]] [Destination [{/a|/b}]]

Parameters

/d
Allows the encrypted files being copied to be saved as decrypted files at the destination.
/v
Verifies that new files are written correctly.
/n
Uses a short file name, if available, when copying a file with a name longer than eight characters, or with a file extension longer than three characters.
/y
Suppresses prompting to confirm that you want to overwrite an existing destination file.
/-y
Prompts you to confirm that you want to overwrite an existing destination file.
/z
Copies networked files in restartable mode.
/a
Indicates an ASCII text file.
/b
Indicates a binary file. (you will need to use this option)
Source
Required. Specifies the location from which you want to copy a file or set of files. Source can consist of a drive letter and colon, a folder name, a file name, or a combination of these.
Destination
Required. Specifies the location to which you want to copy a file or set of files. Destination can consist of a drive letter and colon, a folder name, a file name, or a combination of these.
/?
Displays help at the command prompt.
Remarks
a.. You can copy an ASCII text file that uses an end-of-file character (that is, CTRL+Z) to indicate the end of the file.
b.. Using /a
When /a precedes a list of files on the command line, it applies to all files listed until copy encounters /b. In this case, /b applies to the file preceding /b.

When /a follows a list of files on the command line, it applies to all listed files until copy encounters /b. In this case, /b applies to the file preceding /b.

The effect of /a depends on its position in the command-line string. When /a follows Source, copy treats the file as an ASCII file and copies data that precedes the first end-of-file character.

When /a follows Destination, copy adds an end-of-file character as the last character of the file.

c.. Using /b
/b directs the command interpreter to read the number of bytes specified by the file size in the directory. /b is the default value for copy, unless copy combines files.

When /b precedes a list of files on the command line, it applies to all listed files until copy encounters /a. In this case, /a applies to the file preceding /a.

When /b follows a list of files on the command line, it applies to all listed files until copy encounters /a. In this case, /a applies to the file preceding /a.

The effect of /b depends on its position in the command-line string. When /b follows Source, copy copies the entire file, including any end-of-file character.

When /b follows Destination, copy does not add an end-of-file character.

d.. Using /v
If a write operation cannot be verified an error message appears. Although recording errors rarely occur with copy, you can use /v to verify that critical data has been correctly recorded. The /v command-line option also slows down the copy command, because each sector recorded on the disk must be checked.

e.. Using /y and /-y
If /y is preset in the COPYCMD environment variable, you can override this setting by using /-y at the command line. By default, you are prompted when you replace this setting, unless the copy command is executed in a batch script.

f.. Appending files
To append files, specify a single file for Destination, but multiple files for Source (using wildcard characters or file1+file2+file3 format).

g.. Using /z
If the connection is lost during the copy phase (for example, if the server going offline severs the connection), copy /z resumes after the connection is reestablished. /z also displays the percentage of the copy operation that is completed for each file.

h.. Copying to and from devices (This is what you want to do)
You can substitute a device name for one or more occurrences of Source or Destination. (This is what you want to do)

i.. Using or omitting /b when copying to a device
When Destination is a device (for example, Com1 or Lpt1), /b copies data to the device in binary mode. In binary mode, copy /b copies all characters (that is, including special characters, such as CTRL+C, CTRL+S, CTRL+Z, and carriage return) to the device as data. However, if you omit /b, data is copied to the device in ASCII mode. In ASCII mode, special characters might cause Windows XP to combine files during the copying process. For more information, see "Combining files."

j.. Using the default destination file
If you do not specify a destination file, a copy is created with the same name, creation date, and creation time as the original file, placing the new copy in the current directory on the current drive. If the source file is on the current drive and in the current directory and you do not specify a different drive or directory for the destination file, the copy command stops and displays the following error message:

File cannot be copied onto itself

0 File(s) copied

k.. Combining files
If you specify more than one Source, separating entries with a plus sign (+), copy combines the files into a single file. If you use wildcard characters (that is, * or ?) in Source, but you specify a single file name in Destination, copy combines all files matching the file name in Source and creates a single file with the file name specified in Destination. In either case, copy assumes the combined files are ASCII files unless you use /b.

l.. Copying zero-length files
Copy does not copy files that are 0 bytes long. Use xcopy to copy these files.

m.. Changing the time and date of a file
If you want to assign the current time and date to a file without modifying the file, use the following syntax:

copy /b Source+,,

The commas indicate the omission of the Destination parameter.

n.. Copying files in subdirectories
To copy all of a directory's files and subdirectories, use the xcopy command. For information about xcopy, see Related Topics.

o.. The copy command, with different parameters, is available from the Recovery Console.
Examples
To copy a file called Memo.doc to Letter.doc in the current drive and ensure that an end-of-file character is at the end of the copied file, type:

copy memo.doc letter.doc /a

To copy a file named Robin.typ from the current drive and directory to an existing directory named Birds that is located on drive C, type:

copy robin.typ c:\birds

If the Birds directory does not exist, the file Robin.typ is copied into a file named Birds that is located in the root directory on the disk in drive C.

To copy several files into one file, list several Source files, separate the file names with a plus sign (+), and specify a Destination file that you want to contain the resulting combined file. For example, to combine Mar89.rpt, Apr89.rpt, and May89.rpt, which are located on the current drive and directory, and place them in a file named Report on the current drive and directory, type:

copy mar89.rpt + apr89.rpt + may89.rpt report

When you combine files, copy marks the destination file with the current date and time. If you omit Destination, the files are combined and stored under the name of the file specified first. For example, to combine all four files in Report when a file named Report already exists, type:

copy report + mar89.rpt + apr89.rpt + may89.rpt

You can also combine several files into one file by using wildcard characters (that is, * or ?). For example, to combine all files in the current directory on the current drive that have the extension .txt into one file named Combin.doc, type:

copy *.txt combin.doc

If you want to combine several binary files into one file by using wildcard characters, include /b. This prevents Windows XP from treating CTRL+Z as an end-of-file character. For example, type:

copy /b *.exe combin.exe

Caution

a.. If you combine binary files, the resulting file might be unusable due to internal formatting.
In the following example, copy combines each file that has a .txt extension with its corresponding .ref file. The result is a file with the same file name but with a .doc extension. Copy combines File1.txt with File1.ref to form File1.doc, and then copy combines File2.txt with File2.ref to form File2.doc, and so on. For example, type:

copy *.txt + *.ref *.doc

To combine all files with the .txt extension, and then combine all files with the .ref extension into one file named Combin.doc, type:

copy *.txt + *.ref combin.doc

Formatting legend
Format Meaning
Italic Information that the user must supply
Bold Elements that the user must type exactly as shown
Ellipsis (...) Parameter that can be repeated several times in a command line
Between brackets ([]) Optional items
Between braces ({}); choices separated by pipe (|). Example: {even|odd} Set of choices from which the user must choose only one
Courier font Code or program output

Related Topics


"Talal Itani" <(E-Mail Removed)> wrote in message news:bxgVh.6073$0S1.1960@trnddc01...
>
> Is there a way to send a file to the printer, without opening the
> application that generated the file? I tried to print to a file, from the
> application, then drag that file to the printer, but this did not work. Is
> there a way? Thank you.
>
>

 
Reply With Quote
 
Pegasus \(MVP\)
Guest
Posts: n/a
 
      18th Apr 2007
In your very, very detailed reply you appear to ignore the fact
that most modern printers are not visible under the LPT1:
device name. Your instruction "You will likely be sending
the file to Lpt1" will therefore fail.
 
Reply With Quote
 
Paul Randall
Guest
Posts: n/a
 
      18th Apr 2007

"Talal Itani" <(E-Mail Removed)> wrote in message
news:bxgVh.6073$0S1.1960@trnddc01...
>
> Is there a way to send a file to the printer, without opening the
> application that generated the file? I tried to print to a file, from the
> application, then drag that file to the printer, but this did not work.
> Is there a way? Thank you.


Are you asking for a way to print a .XLS excel file, for example, without
opening Excel?

-Paul Randall


 
Reply With Quote
 
Talal Itani
Guest
Posts: n/a
 
      18th Apr 2007

"Paul Randall" <(E-Mail Removed)> wrote in message
news:eome$(E-Mail Removed)...
>
> "Talal Itani" <(E-Mail Removed)> wrote in message
> news:bxgVh.6073$0S1.1960@trnddc01...
>>
>> Is there a way to send a file to the printer, without opening the
>> application that generated the file? I tried to print to a file, from
>> the application, then drag that file to the printer, but this did not
>> work. Is there a way? Thank you.

>
> Are you asking for a way to print a .XLS excel file, for example, without
> opening Excel?
>
> -Paul Randall
>


Not really. From Excel, if I print a document, I can print that document to
a .prn file. Then, from outside Excel, I should be able to send that .prn
file to a printer.


 
Reply With Quote
 
Paul Randall
Guest
Posts: n/a
 
      19th Apr 2007

"Talal Itani" <(E-Mail Removed)> wrote in message
news:cSvVh.1462$Qp.742@trnddc07...
>
> "Paul Randall" <(E-Mail Removed)> wrote in message
> news:eome$(E-Mail Removed)...
>>
>> "Talal Itani" <(E-Mail Removed)> wrote in message
>> news:bxgVh.6073$0S1.1960@trnddc01...
>>>
>>> Is there a way to send a file to the printer, without opening the
>>> application that generated the file? I tried to print to a file, from
>>> the application, then drag that file to the printer, but this did not
>>> work. Is there a way? Thank you.

>>
>> Are you asking for a way to print a .XLS excel file, for example, without
>> opening Excel?
>>
>> -Paul Randall
>>

>
> Not really. From Excel, if I print a document, I can print that document
> to a .prn file. Then, from outside Excel, I should be able to send that
> .prn file to a printer.


The methods posted by others may work for you and I think printfile will
work too:
..
I also need to send native printer code directly to a USB printer; in my
case Postscript is being sent to the printer. I have installed a utility
called printfile, available for free from
http://www.lerup.com/printfile/descr.html. This utility was written with
postscript in mind, and may pop up a warning if you are sending the .prn
file to a non-postscript printer. But it does send the file directly to the
selected windows printer. In my case, the printer has a dual interface --
Postscript and HP PCL. I have not installed the postscript driver; Windows
installs only the HP PCL type drivers for the printer. So I always get the
warning and my document always prints just fine.

-Paul Randall


 
Reply With Quote
 
Daave
Guest
Posts: n/a
 
      20th Apr 2007
Talal Itani wrote:
> "Paul Randall" <(E-Mail Removed)> wrote in message
> news:eome$(E-Mail Removed)...
>>
>> "Talal Itani" <(E-Mail Removed)> wrote in message
>> news:bxgVh.6073$0S1.1960@trnddc01...
>>>
>>> Is there a way to send a file to the printer, without opening the
>>> application that generated the file? I tried to print to a file,
>>> from the application, then drag that file to the printer, but this
>>> did not work. Is there a way? Thank you.

>>
>> Are you asking for a way to print a .XLS excel file, for example,
>> without opening Excel?


> Not really. From Excel, if I print a document, I can print that
> document to a .prn file. Then, from outside Excel, I should be able
> to send that .prn file to a printer.


See "How to Print From a PRN File" at:

http://filext.com/faq/print_from_prn_file.php



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Printer setup error: cannot create a file when that file already e =?Utf-8?B?TmljayBN?= Windows XP Print / Fax 0 6th Oct 2005 08:15 PM
Can't print to PDF file or main printer but can to another printer =?Utf-8?B?UFogU3RyYXViZQ==?= Microsoft Access Reports 2 10th Nov 2004 03:48 PM
Can I send a PDF file of an Excel file to a printer for printing . =?Utf-8?B?Q2hpdG93bmJhYnM=?= Microsoft Excel Misc 1 21st Oct 2004 11:30 PM
Printer installation Cannot create a file when that file already exists. Steve Kallesser Windows XP Hardware 1 16th Sep 2004 05:37 AM
How to Uncheck File and Printer sharing via registry or batch file? USP Windows XP Setup 0 16th Dec 2003 05:27 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:15 PM.