Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() i have a command button that i am using to try and print a few things, i have the code set up like this : printer.print "hello world!" but when i click the button i get the following error : "Run-Time Error- '424' "Object Required" any ideas on how to fix the problem ? -- pike168 ------------------------------------------------------------------------ pike168's Profile: http://www.excelforum.com/member.php...o&userid=32986 View this thread: http://www.excelforum.com/showthread...hreadid=528922 |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
The VBA line is:
ActiveSheet.PrintOut "pike168" wrote in message ... i have a command button that i am using to try and print a few things, i have the code set up like this : printer.print "hello world!" but when i click the button i get the following error : "Run-Time Error- '424' "Object Required" any ideas on how to fix the problem ? -- pike168 ------------------------------------------------------------------------ pike168's Profile: http://www.excelforum.com/member.php...o&userid=32986 View this thread: http://www.excelforum.com/showthread...hreadid=528922 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() so would the following work : ActiveSheet.PrintOut "hello world" because it doesnt seem to be working for m -- pike16 ----------------------------------------------------------------------- pike168's Profile: http://www.excelforum.com/member.php...fo&userid=3298 View this thread: http://www.excelforum.com/showthread.php?threadid=52892 |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
In excel, you print a range, a worksheet, or a workbook. You don't send strings
directly to the printer with .printout. You can open the printer port and print that way, though: Option Explicit Sub testme01() Open "LPT1:" For Output As #1 Print #1, "Hello world!" Close #1 End Sub pike168 wrote: so would the following work : ActiveSheet.PrintOut "hello world" because it doesnt seem to be working for me -- pike168 ------------------------------------------------------------------------ pike168's Profile: http://www.excelforum.com/member.php...o&userid=32986 View this thread: http://www.excelforum.com/showthread...hreadid=528922 -- Dave Peterson |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
ps. I didn't mean to give the impression that those are the only thing that
..printout applies to. You can select printout in your code and hit F1, then the Applies to link to see all the options. Dave Peterson wrote: In excel, you print a range, a worksheet, or a workbook. You don't send strings directly to the printer with .printout. You can open the printer port and print that way, though: Option Explicit Sub testme01() Open "LPT1:" For Output As #1 Print #1, "Hello world!" Close #1 End Sub pike168 wrote: so would the following work : ActiveSheet.PrintOut "hello world" because it doesnt seem to be working for me -- pike168 ------------------------------------------------------------------------ pike168's Profile: http://www.excelforum.com/member.php...o&userid=32986 View this thread: http://www.excelforum.com/showthread...hreadid=528922 -- Dave Peterson -- Dave Peterson |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I entered into a new Workbook - Sheet1 cell B4 "Hello world"
I then did ALT-F11 to get into VBE; Pressing Control-G took me to the immediate window where I typed.. Activesheet.Printout (then pressed enter) My print then produces a single page with Hello world (only) OK? "pike168" wrote in message ... so would the following work : ActiveSheet.PrintOut "hello world" because it doesnt seem to be working for me -- pike168 ------------------------------------------------------------------------ pike168's Profile: http://www.excelforum.com/member.php...o&userid=32986 View this thread: http://www.excelforum.com/showthread...hreadid=528922 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Print to Excel instead of Printer? | Excel Discussion (Misc queries) | |||
how can I use print preview without having a printer | Excel Discussion (Misc queries) | |||
Unable to Print to Printer | Excel Discussion (Misc queries) | |||
members on my network printer not able to print to default printer | Excel Discussion (Misc queries) | |||
how can I get my printer to print in grayscale ? | Excel Discussion (Misc queries) |