Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
wotrac
Yak Posting Veteran
98 Posts |
Posted - 2002-12-08 : 15:45:09
|
| Is there any way to send a message direct to a printer, from within SQlI am running a stored procedure, as a scheduled job every day. If the procedure is succesful, I would like to inform the user when they get into the office every morning.The rows inserted during the procedure would be printed out as a message and if there had been any errors these would be reported also.Does anyone know if this is possible.Paul |
|
|
ValterBorges
Master Smack Fu Yak Hacker
1429 Posts |
Posted - 2002-12-08 : 17:17:56
|
| Write out the results to a file.http://www.sqlteam.com/item.asp?ItemID=4722Use xp_cmdshell to execute a print statement of the file.PRINT [/D:device] [path]Registring a printernet use lpt1: \\servername\printer /persistent:yes |
 |
|
|
wotrac
Yak Posting Veteran
98 Posts |
Posted - 2002-12-08 : 17:50:46
|
| Brilliant, just what I was looking for.Many ThanksPaul |
 |
|
|
ValterBorges
Master Smack Fu Yak Hacker
1429 Posts |
|
|
|
|
|