Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Automating a Printout

Hi all,
I'm using Excel 2002

From Sheet1 I run a Do Until macro and when it stops I want to print Sheet2
automatically [ the print area is already set].

What do I need to add to the macro between *loop* and *end* to achieve this?

Many thanks

Stella




  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Automating a Printout

Sub Example1()
Dim bFlag as Boolean
Dim cnt as Long
bFlag = False
do
cnt = cnt + 1
if rnd() .995 then
bFlag = True
End if

until bflag = True
Worksheets("sheet2").Printout
msgbox "Number of loops: " & cnt
End Sub

--
Regards,
Tom Ogilvy

"Stella" wrote:

Hi all,
I'm using Excel 2002

From Sheet1 I run a Do Until macro and when it stops I want to print Sheet2
automatically [ the print area is already set].

What do I need to add to the macro between *loop* and *end* to achieve this?

Many thanks

Stella





  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Automating a Printout

Yeah Right : vous plonquere


"Tom Ogilvy" wrote in message
...
Sub Example1()
Dim bFlag as Boolean
Dim cnt as Long
bFlag = False
do
cnt = cnt + 1
if rnd() .995 then
bFlag = True
End if

until bflag = True
Worksheets("sheet2").Printout
msgbox "Number of loops: " & cnt
End Sub

--
Regards,
Tom Ogilvy

"Stella" wrote:

Hi all,
I'm using Excel 2002

From Sheet1 I run a Do Until macro and when it stops I want to print
Sheet2
automatically [ the print area is already set].

What do I need to add to the macro between *loop* and *end* to achieve
this?

Many thanks

Stella







  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Automating a Printout

What is that supposed to mean ?

NickHK

"Stella" wrote in message
...
Yeah Right : vous plonquere


"Tom Ogilvy" wrote in message
...
Sub Example1()
Dim bFlag as Boolean
Dim cnt as Long
bFlag = False
do
cnt = cnt + 1
if rnd() .995 then
bFlag = True
End if

until bflag = True
Worksheets("sheet2").Printout
msgbox "Number of loops: " & cnt
End Sub

--
Regards,
Tom Ogilvy

"Stella" wrote:

Hi all,
I'm using Excel 2002

From Sheet1 I run a Do Until macro and when it stops I want to print
Sheet2
automatically [ the print area is already set].

What do I need to add to the macro between *loop* and *end* to achieve
this?

Many thanks

Stella









  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 290
Default Automating a Printout

I think we know who the plonker is stella,

when posting for help, dont spit on the gift horse


Duncan


NickHK wrote:

What is that supposed to mean ?

NickHK

"Stella" wrote in message
...
Yeah Right : vous plonquere


"Tom Ogilvy" wrote in message
...
Sub Example1()
Dim bFlag as Boolean
Dim cnt as Long
bFlag = False
do
cnt = cnt + 1
if rnd() .995 then
bFlag = True
End if

until bflag = True
Worksheets("sheet2").Printout
msgbox "Number of loops: " & cnt
End Sub

--
Regards,
Tom Ogilvy

"Stella" wrote:

Hi all,
I'm using Excel 2002

From Sheet1 I run a Do Until macro and when it stops I want to print
Sheet2
automatically [ the print area is already set].

What do I need to add to the macro between *loop* and *end* to achieve
this?

Many thanks

Stella








Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Printout using MFC Sachin Excel Worksheet Functions 0 August 4th 08 11:25 AM
no #VALUE! to printout garyww Excel Worksheet Functions 2 August 15th 06 04:19 PM
no #VALUE! to printout garyww Excel Worksheet Functions 1 August 15th 06 10:15 AM
Printout Martin Fishlock[_3_] Excel Programming 7 January 6th 06 03:54 PM
Vba printout Curtis[_6_] Excel Programming 2 October 7th 04 08:46 PM


All times are GMT +1. The time now is 10:52 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"