conditional printing? macro?

here's my situation, i have a workbook with many sheets in it, each sheet if
the default print shortcut button was used would print to 4 pages of A4
paper.

the data on these sheets varies everyday, someday's only 1 page per sheet
would be full of data others 2, 3, or 4 etc. how could i write a macro that
would be able to print only the needed pages?, each page, if it contains any
data would have a value in a totals cell.

so i would need code along these lines

Sheets("sheet1").Select
IF(OR(total1="",total1=0),"don't print","don't print") ELSE set data1 = TRUE
IF(OR(total2="",total2=0),"don't print","don't print") ELSE set data2 = TRUE
IF(OR(total3="",total3=0),"don't print","don't print") ELSE set data3 = TRUE
IF(OR(total4="",total4=0),"don't print","don't print") ELSE set data4 = TRUE

IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1", "don't print")
IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2", "don't print")
IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3", "don't print")
IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4", "don't print")

Hope this helps to explain what im trying to do, and someone is able to code
something that would work.

Many thanks,
Steve


0
me9665 (83)
5/13/2004 2:30:22 PM
excel 39879 articles. 2 followers. Follow

15 Replies
1057 Views

Similar Articles

[PageSpeed] 10

Hi Steven

Try this

Sub test()
If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1, To:=1
If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2, To:=2
If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3, To:=3
If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4, To:=4
End Sub


-- 
Regards Ron de Bruin
http://www.rondebruin.nl


"Steven" <me@where.why> wrote in message news:kELoc.118$6X5.92@newsfe1-win...
> here's my situation, i have a workbook with many sheets in it, each sheet if
> the default print shortcut button was used would print to 4 pages of A4
> paper.
>
> the data on these sheets varies everyday, someday's only 1 page per sheet
> would be full of data others 2, 3, or 4 etc. how could i write a macro that
> would be able to print only the needed pages?, each page, if it contains any
> data would have a value in a totals cell.
>
> so i would need code along these lines
>
> Sheets("sheet1").Select
> IF(OR(total1="",total1=0),"don't print","don't print") ELSE set data1 = TRUE
> IF(OR(total2="",total2=0),"don't print","don't print") ELSE set data2 = TRUE
> IF(OR(total3="",total3=0),"don't print","don't print") ELSE set data3 = TRUE
> IF(OR(total4="",total4=0),"don't print","don't print") ELSE set data4 = TRUE
>
> IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1", "don't print")
> IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2", "don't print")
> IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3", "don't print")
> IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4", "don't print")
>
> Hope this helps to explain what im trying to do, and someone is able to code
> something that would work.
>
> Many thanks,
> Steve
>
>


0
rondebruin (3789)
5/13/2004 3:25:18 PM
Thanks Ron,
how could i test this without printing? if possible?

Steve

"Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> Hi Steven
>
> Try this
>
> Sub test()
> If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1, To:=1
> If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2, To:=2
> If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3, To:=3
> If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4, To:=4
> End Sub
>
>
> -- 
> Regards Ron de Bruin
> http://www.rondebruin.nl
>
>
> "Steven" <me@where.why> wrote in message
news:kELoc.118$6X5.92@newsfe1-win...
> > here's my situation, i have a workbook with many sheets in it, each
sheet if
> > the default print shortcut button was used would print to 4 pages of A4
> > paper.
> >
> > the data on these sheets varies everyday, someday's only 1 page per
sheet
> > would be full of data others 2, 3, or 4 etc. how could i write a macro
that
> > would be able to print only the needed pages?, each page, if it contains
any
> > data would have a value in a totals cell.
> >
> > so i would need code along these lines
> >
> > Sheets("sheet1").Select
> > IF(OR(total1="",total1=0),"don't print","don't print") ELSE set data1 =
TRUE
> > IF(OR(total2="",total2=0),"don't print","don't print") ELSE set data2 =
TRUE
> > IF(OR(total3="",total3=0),"don't print","don't print") ELSE set data3 =
TRUE
> > IF(OR(total4="",total4=0),"don't print","don't print") ELSE set data4 =
TRUE
> >
> > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1", "don't print")
> > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2", "don't print")
> > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3", "don't print")
> > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4", "don't print")
> >
> > Hope this helps to explain what im trying to do, and someone is able to
code
> > something that would work.
> >
> > Many thanks,
> > Steve
> >
> >
>
>


0
me9665 (83)
5/13/2004 4:22:57 PM
Printpreview will not work with From:=1, To:=1

You must print

-- 
Regards Ron de Bruin
http://www.rondebruin.nl


"Steven" <me@where.why> wrote in message news:DhNoc.277$nh.131@newsfe6-gui.server.ntli.net...
> Thanks Ron,
> how could i test this without printing? if possible?
>
> Steve
>
> "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> > Hi Steven
> >
> > Try this
> >
> > Sub test()
> > If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1, To:=1
> > If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2, To:=2
> > If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3, To:=3
> > If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4, To:=4
> > End Sub
> >
> >
> > -- 
> > Regards Ron de Bruin
> > http://www.rondebruin.nl
> >
> >
> > "Steven" <me@where.why> wrote in message
> news:kELoc.118$6X5.92@newsfe1-win...
> > > here's my situation, i have a workbook with many sheets in it, each
> sheet if
> > > the default print shortcut button was used would print to 4 pages of A4
> > > paper.
> > >
> > > the data on these sheets varies everyday, someday's only 1 page per
> sheet
> > > would be full of data others 2, 3, or 4 etc. how could i write a macro
> that
> > > would be able to print only the needed pages?, each page, if it contains
> any
> > > data would have a value in a totals cell.
> > >
> > > so i would need code along these lines
> > >
> > > Sheets("sheet1").Select
> > > IF(OR(total1="",total1=0),"don't print","don't print") ELSE set data1 =
> TRUE
> > > IF(OR(total2="",total2=0),"don't print","don't print") ELSE set data2 =
> TRUE
> > > IF(OR(total3="",total3=0),"don't print","don't print") ELSE set data3 =
> TRUE
> > > IF(OR(total4="",total4=0),"don't print","don't print") ELSE set data4 =
> TRUE
> > >
> > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1", "don't print")
> > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2", "don't print")
> > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3", "don't print")
> > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4", "don't print")
> > >
> > > Hope this helps to explain what im trying to do, and someone is able to
> code
> > > something that would work.
> > >
> > > Many thanks,
> > > Steve
> > >
> > >
> >
> >
>
>


0
rondebruin (3789)
5/13/2004 5:09:36 PM
How about instead of ActiveSheet.PrintOut set up a way to get the range for
the area to print and return it in a MsgBox?
or DeBug Print? or....

-- 
steveb
(Remove 'NOSPAM' from email address if replying direct)


"Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
news:eTegS0QOEHA.2920@tk2msftngp13.phx.gbl...
> Printpreview will not work with From:=1, To:=1
>
> You must print
>
> -- 
> Regards Ron de Bruin
> http://www.rondebruin.nl
>
>
> "Steven" <me@where.why> wrote in message
news:DhNoc.277$nh.131@newsfe6-gui.server.ntli.net...
> > Thanks Ron,
> > how could i test this without printing? if possible?
> >
> > Steve
> >
> > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> > > Hi Steven
> > >
> > > Try this
> > >
> > > Sub test()
> > > If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1, To:=1
> > > If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2, To:=2
> > > If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3, To:=3
> > > If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4, To:=4
> > > End Sub
> > >
> > >
> > > -- 
> > > Regards Ron de Bruin
> > > http://www.rondebruin.nl
> > >
> > >
> > > "Steven" <me@where.why> wrote in message
> > news:kELoc.118$6X5.92@newsfe1-win...
> > > > here's my situation, i have a workbook with many sheets in it, each
> > sheet if
> > > > the default print shortcut button was used would print to 4 pages of
A4
> > > > paper.
> > > >
> > > > the data on these sheets varies everyday, someday's only 1 page per
> > sheet
> > > > would be full of data others 2, 3, or 4 etc. how could i write a
macro
> > that
> > > > would be able to print only the needed pages?, each page, if it
contains
> > any
> > > > data would have a value in a totals cell.
> > > >
> > > > so i would need code along these lines
> > > >
> > > > Sheets("sheet1").Select
> > > > IF(OR(total1="",total1=0),"don't print","don't print") ELSE set
data1 =
> > TRUE
> > > > IF(OR(total2="",total2=0),"don't print","don't print") ELSE set
data2 =
> > TRUE
> > > > IF(OR(total3="",total3=0),"don't print","don't print") ELSE set
data3 =
> > TRUE
> > > > IF(OR(total4="",total4=0),"don't print","don't print") ELSE set
data4 =
> > TRUE
> > > >
> > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1", "don't
print")
> > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2", "don't
print")
> > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3", "don't
print")
> > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4", "don't
print")
> > > >
> > > > Hope this helps to explain what im trying to do, and someone is able
to
> > code
> > > > something that would work.
> > > >
> > > > Many thanks,
> > > > Steve
> > > >
> > > >
> > >
> > >
> >
> >
>
>


0
5/13/2004 6:02:56 PM
Or maybe:

Option Explicit
Sub test()
If Range("total1") > 0 Then ActiveSheet.PrintOut preview:=True, From:=1, To:=1
If Range("total2") > 0 Then ActiveSheet.PrintOut preview:=True, From:=2, To:=2
If Range("total3") > 0 Then ActiveSheet.PrintOut preview:=True, From:=3, To:=3
If Range("total4") > 0 Then ActiveSheet.PrintOut preview:=True, From:=4, To:=4
End Sub

it worked ok for me in xl2002.




steveb wrote:
> 
> How about instead of ActiveSheet.PrintOut set up a way to get the range for
> the area to print and return it in a MsgBox?
> or DeBug Print? or....
> 
> --
> steveb
> (Remove 'NOSPAM' from email address if replying direct)
> 
> "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> news:eTegS0QOEHA.2920@tk2msftngp13.phx.gbl...
> > Printpreview will not work with From:=1, To:=1
> >
> > You must print
> >
> > --
> > Regards Ron de Bruin
> > http://www.rondebruin.nl
> >
> >
> > "Steven" <me@where.why> wrote in message
> news:DhNoc.277$nh.131@newsfe6-gui.server.ntli.net...
> > > Thanks Ron,
> > > how could i test this without printing? if possible?
> > >
> > > Steve
> > >
> > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> > > > Hi Steven
> > > >
> > > > Try this
> > > >
> > > > Sub test()
> > > > If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1, To:=1
> > > > If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2, To:=2
> > > > If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3, To:=3
> > > > If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4, To:=4
> > > > End Sub
> > > >
> > > >
> > > > --
> > > > Regards Ron de Bruin
> > > > http://www.rondebruin.nl
> > > >
> > > >
> > > > "Steven" <me@where.why> wrote in message
> > > news:kELoc.118$6X5.92@newsfe1-win...
> > > > > here's my situation, i have a workbook with many sheets in it, each
> > > sheet if
> > > > > the default print shortcut button was used would print to 4 pages of
> A4
> > > > > paper.
> > > > >
> > > > > the data on these sheets varies everyday, someday's only 1 page per
> > > sheet
> > > > > would be full of data others 2, 3, or 4 etc. how could i write a
> macro
> > > that
> > > > > would be able to print only the needed pages?, each page, if it
> contains
> > > any
> > > > > data would have a value in a totals cell.
> > > > >
> > > > > so i would need code along these lines
> > > > >
> > > > > Sheets("sheet1").Select
> > > > > IF(OR(total1="",total1=0),"don't print","don't print") ELSE set
> data1 =
> > > TRUE
> > > > > IF(OR(total2="",total2=0),"don't print","don't print") ELSE set
> data2 =
> > > TRUE
> > > > > IF(OR(total3="",total3=0),"don't print","don't print") ELSE set
> data3 =
> > > TRUE
> > > > > IF(OR(total4="",total4=0),"don't print","don't print") ELSE set
> data4 =
> > > TRUE
> > > > >
> > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1", "don't
> print")
> > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2", "don't
> print")
> > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3", "don't
> print")
> > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4", "don't
> print")
> > > > >
> > > > > Hope this helps to explain what im trying to do, and someone is able
> to
> > > code
> > > > > something that would work.
> > > > >
> > > > > Many thanks,
> > > > > Steve
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >

-- 

Dave Peterson
ec35720@msn.com
0
ec35720 (10082)
5/13/2004 10:59:16 PM
Thanks Dave

I never use it like this
I always waste trees<g>

-- 
Regards Ron de Bruin
http://www.rondebruin.nl


"Dave Peterson" <ec35720@msn.com> wrote in message news:40A3FDC4.7636F79E@msn.com...
> Or maybe:
>
> Option Explicit
> Sub test()
> If Range("total1") > 0 Then ActiveSheet.PrintOut preview:=True, From:=1, To:=1
> If Range("total2") > 0 Then ActiveSheet.PrintOut preview:=True, From:=2, To:=2
> If Range("total3") > 0 Then ActiveSheet.PrintOut preview:=True, From:=3, To:=3
> If Range("total4") > 0 Then ActiveSheet.PrintOut preview:=True, From:=4, To:=4
> End Sub
>
> it worked ok for me in xl2002.
>
>
>
>
> steveb wrote:
> >
> > How about instead of ActiveSheet.PrintOut set up a way to get the range for
> > the area to print and return it in a MsgBox?
> > or DeBug Print? or....
> >
> > --
> > steveb
> > (Remove 'NOSPAM' from email address if replying direct)
> >
> > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > news:eTegS0QOEHA.2920@tk2msftngp13.phx.gbl...
> > > Printpreview will not work with From:=1, To:=1
> > >
> > > You must print
> > >
> > > --
> > > Regards Ron de Bruin
> > > http://www.rondebruin.nl
> > >
> > >
> > > "Steven" <me@where.why> wrote in message
> > news:DhNoc.277$nh.131@newsfe6-gui.server.ntli.net...
> > > > Thanks Ron,
> > > > how could i test this without printing? if possible?
> > > >
> > > > Steve
> > > >
> > > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > > news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> > > > > Hi Steven
> > > > >
> > > > > Try this
> > > > >
> > > > > Sub test()
> > > > > If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1, To:=1
> > > > > If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2, To:=2
> > > > > If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3, To:=3
> > > > > If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4, To:=4
> > > > > End Sub
> > > > >
> > > > >
> > > > > --
> > > > > Regards Ron de Bruin
> > > > > http://www.rondebruin.nl
> > > > >
> > > > >
> > > > > "Steven" <me@where.why> wrote in message
> > > > news:kELoc.118$6X5.92@newsfe1-win...
> > > > > > here's my situation, i have a workbook with many sheets in it, each
> > > > sheet if
> > > > > > the default print shortcut button was used would print to 4 pages of
> > A4
> > > > > > paper.
> > > > > >
> > > > > > the data on these sheets varies everyday, someday's only 1 page per
> > > > sheet
> > > > > > would be full of data others 2, 3, or 4 etc. how could i write a
> > macro
> > > > that
> > > > > > would be able to print only the needed pages?, each page, if it
> > contains
> > > > any
> > > > > > data would have a value in a totals cell.
> > > > > >
> > > > > > so i would need code along these lines
> > > > > >
> > > > > > Sheets("sheet1").Select
> > > > > > IF(OR(total1="",total1=0),"don't print","don't print") ELSE set
> > data1 =
> > > > TRUE
> > > > > > IF(OR(total2="",total2=0),"don't print","don't print") ELSE set
> > data2 =
> > > > TRUE
> > > > > > IF(OR(total3="",total3=0),"don't print","don't print") ELSE set
> > data3 =
> > > > TRUE
> > > > > > IF(OR(total4="",total4=0),"don't print","don't print") ELSE set
> > data4 =
> > > > TRUE
> > > > > >
> > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1", "don't
> > print")
> > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2", "don't
> > print")
> > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3", "don't
> > print")
> > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4", "don't
> > print")
> > > > > >
> > > > > > Hope this helps to explain what im trying to do, and someone is able
> > to
> > > > code
> > > > > > something that would work.
> > > > > >
> > > > > > Many thanks,
> > > > > > Steve
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
>
> -- 
>
> Dave Peterson
> ec35720@msn.com


0
rondebruin (3789)
5/14/2004 1:59:08 PM
For the most part, I keep my (personal) printer off.

In fact, it's paused (under control panel).

Before I did this, I used all the trees in the Sahara Forest.  Well, it's a
desert NOW!

(It's an old joke, but I'm an old man!)



Ron de Bruin wrote:
> 
> Thanks Dave
> 
> I never use it like this
> I always waste trees<g>
> 
> --
> Regards Ron de Bruin
> http://www.rondebruin.nl
> 
> "Dave Peterson" <ec35720@msn.com> wrote in message news:40A3FDC4.7636F79E@msn.com...
> > Or maybe:
> >
> > Option Explicit
> > Sub test()
> > If Range("total1") > 0 Then ActiveSheet.PrintOut preview:=True, From:=1, To:=1
> > If Range("total2") > 0 Then ActiveSheet.PrintOut preview:=True, From:=2, To:=2
> > If Range("total3") > 0 Then ActiveSheet.PrintOut preview:=True, From:=3, To:=3
> > If Range("total4") > 0 Then ActiveSheet.PrintOut preview:=True, From:=4, To:=4
> > End Sub
> >
> > it worked ok for me in xl2002.
> >
> >
> >
> >
> > steveb wrote:
> > >
> > > How about instead of ActiveSheet.PrintOut set up a way to get the range for
> > > the area to print and return it in a MsgBox?
> > > or DeBug Print? or....
> > >
> > > --
> > > steveb
> > > (Remove 'NOSPAM' from email address if replying direct)
> > >
> > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > news:eTegS0QOEHA.2920@tk2msftngp13.phx.gbl...
> > > > Printpreview will not work with From:=1, To:=1
> > > >
> > > > You must print
> > > >
> > > > --
> > > > Regards Ron de Bruin
> > > > http://www.rondebruin.nl
> > > >
> > > >
> > > > "Steven" <me@where.why> wrote in message
> > > news:DhNoc.277$nh.131@newsfe6-gui.server.ntli.net...
> > > > > Thanks Ron,
> > > > > how could i test this without printing? if possible?
> > > > >
> > > > > Steve
> > > > >
> > > > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > > > news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> > > > > > Hi Steven
> > > > > >
> > > > > > Try this
> > > > > >
> > > > > > Sub test()
> > > > > > If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1, To:=1
> > > > > > If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2, To:=2
> > > > > > If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3, To:=3
> > > > > > If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4, To:=4
> > > > > > End Sub
> > > > > >
> > > > > >
> > > > > > --
> > > > > > Regards Ron de Bruin
> > > > > > http://www.rondebruin.nl
> > > > > >
> > > > > >
> > > > > > "Steven" <me@where.why> wrote in message
> > > > > news:kELoc.118$6X5.92@newsfe1-win...
> > > > > > > here's my situation, i have a workbook with many sheets in it, each
> > > > > sheet if
> > > > > > > the default print shortcut button was used would print to 4 pages of
> > > A4
> > > > > > > paper.
> > > > > > >
> > > > > > > the data on these sheets varies everyday, someday's only 1 page per
> > > > > sheet
> > > > > > > would be full of data others 2, 3, or 4 etc. how could i write a
> > > macro
> > > > > that
> > > > > > > would be able to print only the needed pages?, each page, if it
> > > contains
> > > > > any
> > > > > > > data would have a value in a totals cell.
> > > > > > >
> > > > > > > so i would need code along these lines
> > > > > > >
> > > > > > > Sheets("sheet1").Select
> > > > > > > IF(OR(total1="",total1=0),"don't print","don't print") ELSE set
> > > data1 =
> > > > > TRUE
> > > > > > > IF(OR(total2="",total2=0),"don't print","don't print") ELSE set
> > > data2 =
> > > > > TRUE
> > > > > > > IF(OR(total3="",total3=0),"don't print","don't print") ELSE set
> > > data3 =
> > > > > TRUE
> > > > > > > IF(OR(total4="",total4=0),"don't print","don't print") ELSE set
> > > data4 =
> > > > > TRUE
> > > > > > >
> > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1", "don't
> > > print")
> > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2", "don't
> > > print")
> > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3", "don't
> > > print")
> > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4", "don't
> > > print")
> > > > > > >
> > > > > > > Hope this helps to explain what im trying to do, and someone is able
> > > to
> > > > > code
> > > > > > > something that would work.
> > > > > > >
> > > > > > > Many thanks,
> > > > > > > Steve
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> >
> > --
> >
> > Dave Peterson
> > ec35720@msn.com

-- 

Dave Peterson
ec35720@msn.com
0
ec35720 (10082)
5/14/2004 11:10:57 PM
what code would i need to use on new commandbutton to do the following:

1) select sheet 1
2) run another commandbutton from within that sheet "Private Sub
CommandButton2_Click()
     SortKeys = "EC"
     Call SortAllRanges
 End Sub"
3) look at "total4" if greater than 0 print pages 1 to 4, 1 copy, goto next
                         else
                         look at "total3" if greater than 0 print pages 1 to
3, 1 copy, goto next
                                                else
                                                look at "total2" if greater
than 0 print pages 1 to 2, 1 copy, goto next
                                                                      else
                                                                     look at
"total1" if greater than 0 print pages 1 to 1, 1 copy, goto next

else

end if
4) select sheet 2
5) same as 2)
6) same as 3)
7) select sheet 3

i would be very grateful for your help as this would enable me to setup lots
of different auto print options for multiple worksheets.

Steve

"Dave Peterson" <ec35720@msn.com> wrote in message
news:40A3FDC4.7636F79E@msn.com...
> Or maybe:
>
> Option Explicit
> Sub test()
> If Range("total1") > 0 Then ActiveSheet.PrintOut preview:=True, From:=1,
To:=1
> If Range("total2") > 0 Then ActiveSheet.PrintOut preview:=True, From:=2,
To:=2
> If Range("total3") > 0 Then ActiveSheet.PrintOut preview:=True, From:=3,
To:=3
> If Range("total4") > 0 Then ActiveSheet.PrintOut preview:=True, From:=4,
To:=4
> End Sub
>
> it worked ok for me in xl2002.
>
>
>
>
> steveb wrote:
> >
> > How about instead of ActiveSheet.PrintOut set up a way to get the range
for
> > the area to print and return it in a MsgBox?
> > or DeBug Print? or....
> >
> > --
> > steveb
> > (Remove 'NOSPAM' from email address if replying direct)
> >
> > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > news:eTegS0QOEHA.2920@tk2msftngp13.phx.gbl...
> > > Printpreview will not work with From:=1, To:=1
> > >
> > > You must print
> > >
> > > --
> > > Regards Ron de Bruin
> > > http://www.rondebruin.nl
> > >
> > >
> > > "Steven" <me@where.why> wrote in message
> > news:DhNoc.277$nh.131@newsfe6-gui.server.ntli.net...
> > > > Thanks Ron,
> > > > how could i test this without printing? if possible?
> > > >
> > > > Steve
> > > >
> > > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > > news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> > > > > Hi Steven
> > > > >
> > > > > Try this
> > > > >
> > > > > Sub test()
> > > > > If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1, To:=1
> > > > > If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2, To:=2
> > > > > If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3, To:=3
> > > > > If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4, To:=4
> > > > > End Sub
> > > > >
> > > > >
> > > > > --
> > > > > Regards Ron de Bruin
> > > > > http://www.rondebruin.nl
> > > > >
> > > > >
> > > > > "Steven" <me@where.why> wrote in message
> > > > news:kELoc.118$6X5.92@newsfe1-win...
> > > > > > here's my situation, i have a workbook with many sheets in it,
each
> > > > sheet if
> > > > > > the default print shortcut button was used would print to 4
pages of
> > A4
> > > > > > paper.
> > > > > >
> > > > > > the data on these sheets varies everyday, someday's only 1 page
per
> > > > sheet
> > > > > > would be full of data others 2, 3, or 4 etc. how could i write a
> > macro
> > > > that
> > > > > > would be able to print only the needed pages?, each page, if it
> > contains
> > > > any
> > > > > > data would have a value in a totals cell.
> > > > > >
> > > > > > so i would need code along these lines
> > > > > >
> > > > > > Sheets("sheet1").Select
> > > > > > IF(OR(total1="",total1=0),"don't print","don't print") ELSE set
> > data1 =
> > > > TRUE
> > > > > > IF(OR(total2="",total2=0),"don't print","don't print") ELSE set
> > data2 =
> > > > TRUE
> > > > > > IF(OR(total3="",total3=0),"don't print","don't print") ELSE set
> > data3 =
> > > > TRUE
> > > > > > IF(OR(total4="",total4=0),"don't print","don't print") ELSE set
> > data4 =
> > > > TRUE
> > > > > >
> > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1", "don't
> > print")
> > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2", "don't
> > print")
> > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3", "don't
> > print")
> > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4", "don't
> > print")
> > > > > >
> > > > > > Hope this helps to explain what im trying to do, and someone is
able
> > to
> > > > code
> > > > > > something that would work.
> > > > > >
> > > > > > Many thanks,
> > > > > > Steve
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
>
> -- 
>
> Dave Peterson
> ec35720@msn.com


0
me9665 (83)
5/16/2004 4:34:59 PM
One way:

If Range("total4").Value > 0 Then
    ActiveSheet.PrintOut preview:=True, From:=4, To:=4
ElseIf Range("total3").Value > 0 Then
    ActiveSheet.PrintOut preview:=True, From:=3, To:=3
ElseIf Range("total2").Value > 0 Then
    ActiveSheet.PrintOut preview:=True, From:=2, To:=2
ElseIf Range("total1").Value > 0 Then
    ActiveSheet.PrintOut preview:=True, From:=1, To:=1
Else
    'do nothing
End If



Steven wrote:
> 
> what code would i need to use on new commandbutton to do the following:
> 
> 1) select sheet 1
> 2) run another commandbutton from within that sheet "Private Sub
> CommandButton2_Click()
>      SortKeys = "EC"
>      Call SortAllRanges
>  End Sub"
> 3) look at "total4" if greater than 0 print pages 1 to 4, 1 copy, goto next
>                          else
>                          look at "total3" if greater than 0 print pages 1 to
> 3, 1 copy, goto next
>                                                 else
>                                                 look at "total2" if greater
> than 0 print pages 1 to 2, 1 copy, goto next
>                                                                       else
>                                                                      look at
> "total1" if greater than 0 print pages 1 to 1, 1 copy, goto next
> 
> else
> 
> end if
> 4) select sheet 2
> 5) same as 2)
> 6) same as 3)
> 7) select sheet 3
> 
> i would be very grateful for your help as this would enable me to setup lots
> of different auto print options for multiple worksheets.
> 
> Steve
> 
> "Dave Peterson" <ec35720@msn.com> wrote in message
> news:40A3FDC4.7636F79E@msn.com...
> > Or maybe:
> >
> > Option Explicit
> > Sub test()
> > If Range("total1") > 0 Then ActiveSheet.PrintOut preview:=True, From:=1,
> To:=1
> > If Range("total2") > 0 Then ActiveSheet.PrintOut preview:=True, From:=2,
> To:=2
> > If Range("total3") > 0 Then ActiveSheet.PrintOut preview:=True, From:=3,
> To:=3
> > If Range("total4") > 0 Then ActiveSheet.PrintOut preview:=True, From:=4,
> To:=4
> > End Sub
> >
> > it worked ok for me in xl2002.
> >
> >
> >
> >
> > steveb wrote:
> > >
> > > How about instead of ActiveSheet.PrintOut set up a way to get the range
> for
> > > the area to print and return it in a MsgBox?
> > > or DeBug Print? or....
> > >
> > > --
> > > steveb
> > > (Remove 'NOSPAM' from email address if replying direct)
> > >
> > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > news:eTegS0QOEHA.2920@tk2msftngp13.phx.gbl...
> > > > Printpreview will not work with From:=1, To:=1
> > > >
> > > > You must print
> > > >
> > > > --
> > > > Regards Ron de Bruin
> > > > http://www.rondebruin.nl
> > > >
> > > >
> > > > "Steven" <me@where.why> wrote in message
> > > news:DhNoc.277$nh.131@newsfe6-gui.server.ntli.net...
> > > > > Thanks Ron,
> > > > > how could i test this without printing? if possible?
> > > > >
> > > > > Steve
> > > > >
> > > > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > > > news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> > > > > > Hi Steven
> > > > > >
> > > > > > Try this
> > > > > >
> > > > > > Sub test()
> > > > > > If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1, To:=1
> > > > > > If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2, To:=2
> > > > > > If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3, To:=3
> > > > > > If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4, To:=4
> > > > > > End Sub
> > > > > >
> > > > > >
> > > > > > --
> > > > > > Regards Ron de Bruin
> > > > > > http://www.rondebruin.nl
> > > > > >
> > > > > >
> > > > > > "Steven" <me@where.why> wrote in message
> > > > > news:kELoc.118$6X5.92@newsfe1-win...
> > > > > > > here's my situation, i have a workbook with many sheets in it,
> each
> > > > > sheet if
> > > > > > > the default print shortcut button was used would print to 4
> pages of
> > > A4
> > > > > > > paper.
> > > > > > >
> > > > > > > the data on these sheets varies everyday, someday's only 1 page
> per
> > > > > sheet
> > > > > > > would be full of data others 2, 3, or 4 etc. how could i write a
> > > macro
> > > > > that
> > > > > > > would be able to print only the needed pages?, each page, if it
> > > contains
> > > > > any
> > > > > > > data would have a value in a totals cell.
> > > > > > >
> > > > > > > so i would need code along these lines
> > > > > > >
> > > > > > > Sheets("sheet1").Select
> > > > > > > IF(OR(total1="",total1=0),"don't print","don't print") ELSE set
> > > data1 =
> > > > > TRUE
> > > > > > > IF(OR(total2="",total2=0),"don't print","don't print") ELSE set
> > > data2 =
> > > > > TRUE
> > > > > > > IF(OR(total3="",total3=0),"don't print","don't print") ELSE set
> > > data3 =
> > > > > TRUE
> > > > > > > IF(OR(total4="",total4=0),"don't print","don't print") ELSE set
> > > data4 =
> > > > > TRUE
> > > > > > >
> > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1", "don't
> > > print")
> > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2", "don't
> > > print")
> > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3", "don't
> > > print")
> > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4", "don't
> > > print")
> > > > > > >
> > > > > > > Hope this helps to explain what im trying to do, and someone is
> able
> > > to
> > > > > code
> > > > > > > something that would work.
> > > > > > >
> > > > > > > Many thanks,
> > > > > > > Steve
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> >
> > --
> >
> > Dave Peterson
> > ec35720@msn.com

-- 

Dave Peterson
ec35720@msn.com
0
ec35720 (10082)
5/16/2004 8:48:31 PM
Dave could you explain what this code does please because im not sure if it
does everything i would like, many thanks.

Steve

"Dave Peterson" <ec35720@msn.com> wrote in message
news:40A7D39F.56E17F62@msn.com...
> One way:
>
> If Range("total4").Value > 0 Then
>     ActiveSheet.PrintOut preview:=True, From:=4, To:=4
> ElseIf Range("total3").Value > 0 Then
>     ActiveSheet.PrintOut preview:=True, From:=3, To:=3
> ElseIf Range("total2").Value > 0 Then
>     ActiveSheet.PrintOut preview:=True, From:=2, To:=2
> ElseIf Range("total1").Value > 0 Then
>     ActiveSheet.PrintOut preview:=True, From:=1, To:=1
> Else
>     'do nothing
> End If
>
>
>
> Steven wrote:
> >
> > what code would i need to use on new commandbutton to do the following:
> >
> > 1) select sheet 1
> > 2) run another commandbutton from within that sheet "Private Sub
> > CommandButton2_Click()
> >      SortKeys = "EC"
> >      Call SortAllRanges
> >  End Sub"
> > 3) look at "total4" if greater than 0 print pages 1 to 4, 1 copy, goto
next
> >                          else
> >                          look at "total3" if greater than 0 print pages
1 to
> > 3, 1 copy, goto next
> >                                                 else
> >                                                 look at "total2" if
greater
> > than 0 print pages 1 to 2, 1 copy, goto next
> >
else
> >
look at
> > "total1" if greater than 0 print pages 1 to 1, 1 copy, goto next
> >
> > else
> >
> > end if
> > 4) select sheet 2
> > 5) same as 2)
> > 6) same as 3)
> > 7) select sheet 3
> >
> > i would be very grateful for your help as this would enable me to setup
lots
> > of different auto print options for multiple worksheets.
> >
> > Steve
> >
> > "Dave Peterson" <ec35720@msn.com> wrote in message
> > news:40A3FDC4.7636F79E@msn.com...
> > > Or maybe:
> > >
> > > Option Explicit
> > > Sub test()
> > > If Range("total1") > 0 Then ActiveSheet.PrintOut preview:=True,
From:=1,
> > To:=1
> > > If Range("total2") > 0 Then ActiveSheet.PrintOut preview:=True,
From:=2,
> > To:=2
> > > If Range("total3") > 0 Then ActiveSheet.PrintOut preview:=True,
From:=3,
> > To:=3
> > > If Range("total4") > 0 Then ActiveSheet.PrintOut preview:=True,
From:=4,
> > To:=4
> > > End Sub
> > >
> > > it worked ok for me in xl2002.
> > >
> > >
> > >
> > >
> > > steveb wrote:
> > > >
> > > > How about instead of ActiveSheet.PrintOut set up a way to get the
range
> > for
> > > > the area to print and return it in a MsgBox?
> > > > or DeBug Print? or....
> > > >
> > > > --
> > > > steveb
> > > > (Remove 'NOSPAM' from email address if replying direct)
> > > >
> > > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > > news:eTegS0QOEHA.2920@tk2msftngp13.phx.gbl...
> > > > > Printpreview will not work with From:=1, To:=1
> > > > >
> > > > > You must print
> > > > >
> > > > > --
> > > > > Regards Ron de Bruin
> > > > > http://www.rondebruin.nl
> > > > >
> > > > >
> > > > > "Steven" <me@where.why> wrote in message
> > > > news:DhNoc.277$nh.131@newsfe6-gui.server.ntli.net...
> > > > > > Thanks Ron,
> > > > > > how could i test this without printing? if possible?
> > > > > >
> > > > > > Steve
> > > > > >
> > > > > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > > > > news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> > > > > > > Hi Steven
> > > > > > >
> > > > > > > Try this
> > > > > > >
> > > > > > > Sub test()
> > > > > > > If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1,
To:=1
> > > > > > > If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2,
To:=2
> > > > > > > If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3,
To:=3
> > > > > > > If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4,
To:=4
> > > > > > > End Sub
> > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > > Regards Ron de Bruin
> > > > > > > http://www.rondebruin.nl
> > > > > > >
> > > > > > >
> > > > > > > "Steven" <me@where.why> wrote in message
> > > > > > news:kELoc.118$6X5.92@newsfe1-win...
> > > > > > > > here's my situation, i have a workbook with many sheets in
it,
> > each
> > > > > > sheet if
> > > > > > > > the default print shortcut button was used would print to 4
> > pages of
> > > > A4
> > > > > > > > paper.
> > > > > > > >
> > > > > > > > the data on these sheets varies everyday, someday's only 1
page
> > per
> > > > > > sheet
> > > > > > > > would be full of data others 2, 3, or 4 etc. how could i
write a
> > > > macro
> > > > > > that
> > > > > > > > would be able to print only the needed pages?, each page, if
it
> > > > contains
> > > > > > any
> > > > > > > > data would have a value in a totals cell.
> > > > > > > >
> > > > > > > > so i would need code along these lines
> > > > > > > >
> > > > > > > > Sheets("sheet1").Select
> > > > > > > > IF(OR(total1="",total1=0),"don't print","don't print") ELSE
set
> > > > data1 =
> > > > > > TRUE
> > > > > > > > IF(OR(total2="",total2=0),"don't print","don't print") ELSE
set
> > > > data2 =
> > > > > > TRUE
> > > > > > > > IF(OR(total3="",total3=0),"don't print","don't print") ELSE
set
> > > > data3 =
> > > > > > TRUE
> > > > > > > > IF(OR(total4="",total4=0),"don't print","don't print") ELSE
set
> > > > data4 =
> > > > > > TRUE
> > > > > > > >
> > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1",
"don't
> > > > print")
> > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2",
"don't
> > > > print")
> > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3",
"don't
> > > > print")
> > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4",
"don't
> > > > print")
> > > > > > > >
> > > > > > > > Hope this helps to explain what im trying to do, and someone
is
> > able
> > > > to
> > > > > > code
> > > > > > > > something that would work.
> > > > > > > >
> > > > > > > > Many thanks,
> > > > > > > > Steve
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > >
> > > --
> > >
> > > Dave Peterson
> > > ec35720@msn.com
>
> -- 
>
> Dave Peterson
> ec35720@msn.com


0
me9665 (83)
5/16/2004 9:08:17 PM
if total4 is bigger than 0, then print
if it's not, then check total3.  if that's bigger than 0, then print.
if it's not,....

And so forth.

You may want to test it against a small version of your workbook to see if it
works the way you want.



Steven wrote:
> 
> Dave could you explain what this code does please because im not sure if it
> does everything i would like, many thanks.
> 
> Steve
> 
> "Dave Peterson" <ec35720@msn.com> wrote in message
> news:40A7D39F.56E17F62@msn.com...
> > One way:
> >
> > If Range("total4").Value > 0 Then
> >     ActiveSheet.PrintOut preview:=True, From:=4, To:=4
> > ElseIf Range("total3").Value > 0 Then
> >     ActiveSheet.PrintOut preview:=True, From:=3, To:=3
> > ElseIf Range("total2").Value > 0 Then
> >     ActiveSheet.PrintOut preview:=True, From:=2, To:=2
> > ElseIf Range("total1").Value > 0 Then
> >     ActiveSheet.PrintOut preview:=True, From:=1, To:=1
> > Else
> >     'do nothing
> > End If
> >
> >
> >
> > Steven wrote:
> > >
> > > what code would i need to use on new commandbutton to do the following:
> > >
> > > 1) select sheet 1
> > > 2) run another commandbutton from within that sheet "Private Sub
> > > CommandButton2_Click()
> > >      SortKeys = "EC"
> > >      Call SortAllRanges
> > >  End Sub"
> > > 3) look at "total4" if greater than 0 print pages 1 to 4, 1 copy, goto
> next
> > >                          else
> > >                          look at "total3" if greater than 0 print pages
> 1 to
> > > 3, 1 copy, goto next
> > >                                                 else
> > >                                                 look at "total2" if
> greater
> > > than 0 print pages 1 to 2, 1 copy, goto next
> > >
> else
> > >
> look at
> > > "total1" if greater than 0 print pages 1 to 1, 1 copy, goto next
> > >
> > > else
> > >
> > > end if
> > > 4) select sheet 2
> > > 5) same as 2)
> > > 6) same as 3)
> > > 7) select sheet 3
> > >
> > > i would be very grateful for your help as this would enable me to setup
> lots
> > > of different auto print options for multiple worksheets.
> > >
> > > Steve
> > >
> > > "Dave Peterson" <ec35720@msn.com> wrote in message
> > > news:40A3FDC4.7636F79E@msn.com...
> > > > Or maybe:
> > > >
> > > > Option Explicit
> > > > Sub test()
> > > > If Range("total1") > 0 Then ActiveSheet.PrintOut preview:=True,
> From:=1,
> > > To:=1
> > > > If Range("total2") > 0 Then ActiveSheet.PrintOut preview:=True,
> From:=2,
> > > To:=2
> > > > If Range("total3") > 0 Then ActiveSheet.PrintOut preview:=True,
> From:=3,
> > > To:=3
> > > > If Range("total4") > 0 Then ActiveSheet.PrintOut preview:=True,
> From:=4,
> > > To:=4
> > > > End Sub
> > > >
> > > > it worked ok for me in xl2002.
> > > >
> > > >
> > > >
> > > >
> > > > steveb wrote:
> > > > >
> > > > > How about instead of ActiveSheet.PrintOut set up a way to get the
> range
> > > for
> > > > > the area to print and return it in a MsgBox?
> > > > > or DeBug Print? or....
> > > > >
> > > > > --
> > > > > steveb
> > > > > (Remove 'NOSPAM' from email address if replying direct)
> > > > >
> > > > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > > > news:eTegS0QOEHA.2920@tk2msftngp13.phx.gbl...
> > > > > > Printpreview will not work with From:=1, To:=1
> > > > > >
> > > > > > You must print
> > > > > >
> > > > > > --
> > > > > > Regards Ron de Bruin
> > > > > > http://www.rondebruin.nl
> > > > > >
> > > > > >
> > > > > > "Steven" <me@where.why> wrote in message
> > > > > news:DhNoc.277$nh.131@newsfe6-gui.server.ntli.net...
> > > > > > > Thanks Ron,
> > > > > > > how could i test this without printing? if possible?
> > > > > > >
> > > > > > > Steve
> > > > > > >
> > > > > > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > > > > > news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> > > > > > > > Hi Steven
> > > > > > > >
> > > > > > > > Try this
> > > > > > > >
> > > > > > > > Sub test()
> > > > > > > > If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1,
> To:=1
> > > > > > > > If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2,
> To:=2
> > > > > > > > If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3,
> To:=3
> > > > > > > > If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4,
> To:=4
> > > > > > > > End Sub
> > > > > > > >
> > > > > > > >
> > > > > > > > --
> > > > > > > > Regards Ron de Bruin
> > > > > > > > http://www.rondebruin.nl
> > > > > > > >
> > > > > > > >
> > > > > > > > "Steven" <me@where.why> wrote in message
> > > > > > > news:kELoc.118$6X5.92@newsfe1-win...
> > > > > > > > > here's my situation, i have a workbook with many sheets in
> it,
> > > each
> > > > > > > sheet if
> > > > > > > > > the default print shortcut button was used would print to 4
> > > pages of
> > > > > A4
> > > > > > > > > paper.
> > > > > > > > >
> > > > > > > > > the data on these sheets varies everyday, someday's only 1
> page
> > > per
> > > > > > > sheet
> > > > > > > > > would be full of data others 2, 3, or 4 etc. how could i
> write a
> > > > > macro
> > > > > > > that
> > > > > > > > > would be able to print only the needed pages?, each page, if
> it
> > > > > contains
> > > > > > > any
> > > > > > > > > data would have a value in a totals cell.
> > > > > > > > >
> > > > > > > > > so i would need code along these lines
> > > > > > > > >
> > > > > > > > > Sheets("sheet1").Select
> > > > > > > > > IF(OR(total1="",total1=0),"don't print","don't print") ELSE
> set
> > > > > data1 =
> > > > > > > TRUE
> > > > > > > > > IF(OR(total2="",total2=0),"don't print","don't print") ELSE
> set
> > > > > data2 =
> > > > > > > TRUE
> > > > > > > > > IF(OR(total3="",total3=0),"don't print","don't print") ELSE
> set
> > > > > data3 =
> > > > > > > TRUE
> > > > > > > > > IF(OR(total4="",total4=0),"don't print","don't print") ELSE
> set
> > > > > data4 =
> > > > > > > TRUE
> > > > > > > > >
> > > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1",
> "don't
> > > > > print")
> > > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2",
> "don't
> > > > > print")
> > > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3",
> "don't
> > > > > print")
> > > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4",
> "don't
> > > > > print")
> > > > > > > > >
> > > > > > > > > Hope this helps to explain what im trying to do, and someone
> is
> > > able
> > > > > to
> > > > > > > code
> > > > > > > > > something that would work.
> > > > > > > > >
> > > > > > > > > Many thanks,
> > > > > > > > > Steve
> > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > >
> > > > --
> > > >
> > > > Dave Peterson
> > > > ec35720@msn.com
> >
> > --
> >
> > Dave Peterson
> > ec35720@msn.com

-- 

Dave Peterson
ec35720@msn.com
0
ec35720 (10082)
5/16/2004 9:32:27 PM
will it look at all sheets, only active or only ones listed in the macro?

Many thanks
Steve

"Dave Peterson" <ec35720@msn.com> wrote in message
news:40A7DDEB.F12E56D3@msn.com...
> if total4 is bigger than 0, then print
> if it's not, then check total3.  if that's bigger than 0, then print.
> if it's not,....
>
> And so forth.
>
> You may want to test it against a small version of your workbook to see if
it
> works the way you want.
>
>
>
> Steven wrote:
> >
> > Dave could you explain what this code does please because im not sure if
it
> > does everything i would like, many thanks.
> >
> > Steve
> >
> > "Dave Peterson" <ec35720@msn.com> wrote in message
> > news:40A7D39F.56E17F62@msn.com...
> > > One way:
> > >
> > > If Range("total4").Value > 0 Then
> > >     ActiveSheet.PrintOut preview:=True, From:=4, To:=4
> > > ElseIf Range("total3").Value > 0 Then
> > >     ActiveSheet.PrintOut preview:=True, From:=3, To:=3
> > > ElseIf Range("total2").Value > 0 Then
> > >     ActiveSheet.PrintOut preview:=True, From:=2, To:=2
> > > ElseIf Range("total1").Value > 0 Then
> > >     ActiveSheet.PrintOut preview:=True, From:=1, To:=1
> > > Else
> > >     'do nothing
> > > End If
> > >
> > >
> > >
> > > Steven wrote:
> > > >
> > > > what code would i need to use on new commandbutton to do the
following:
> > > >
> > > > 1) select sheet 1
> > > > 2) run another commandbutton from within that sheet "Private Sub
> > > > CommandButton2_Click()
> > > >      SortKeys = "EC"
> > > >      Call SortAllRanges
> > > >  End Sub"
> > > > 3) look at "total4" if greater than 0 print pages 1 to 4, 1 copy,
goto
> > next
> > > >                          else
> > > >                          look at "total3" if greater than 0 print
pages
> > 1 to
> > > > 3, 1 copy, goto next
> > > >                                                 else
> > > >                                                 look at "total2" if
> > greater
> > > > than 0 print pages 1 to 2, 1 copy, goto next
> > > >
> > else
> > > >
> > look at
> > > > "total1" if greater than 0 print pages 1 to 1, 1 copy, goto next
> > > >
> > > > else
> > > >
> > > > end if
> > > > 4) select sheet 2
> > > > 5) same as 2)
> > > > 6) same as 3)
> > > > 7) select sheet 3
> > > >
> > > > i would be very grateful for your help as this would enable me to
setup
> > lots
> > > > of different auto print options for multiple worksheets.
> > > >
> > > > Steve
> > > >
> > > > "Dave Peterson" <ec35720@msn.com> wrote in message
> > > > news:40A3FDC4.7636F79E@msn.com...
> > > > > Or maybe:
> > > > >
> > > > > Option Explicit
> > > > > Sub test()
> > > > > If Range("total1") > 0 Then ActiveSheet.PrintOut preview:=True,
> > From:=1,
> > > > To:=1
> > > > > If Range("total2") > 0 Then ActiveSheet.PrintOut preview:=True,
> > From:=2,
> > > > To:=2
> > > > > If Range("total3") > 0 Then ActiveSheet.PrintOut preview:=True,
> > From:=3,
> > > > To:=3
> > > > > If Range("total4") > 0 Then ActiveSheet.PrintOut preview:=True,
> > From:=4,
> > > > To:=4
> > > > > End Sub
> > > > >
> > > > > it worked ok for me in xl2002.
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > steveb wrote:
> > > > > >
> > > > > > How about instead of ActiveSheet.PrintOut set up a way to get
the
> > range
> > > > for
> > > > > > the area to print and return it in a MsgBox?
> > > > > > or DeBug Print? or....
> > > > > >
> > > > > > --
> > > > > > steveb
> > > > > > (Remove 'NOSPAM' from email address if replying direct)
> > > > > >
> > > > > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > > > > news:eTegS0QOEHA.2920@tk2msftngp13.phx.gbl...
> > > > > > > Printpreview will not work with From:=1, To:=1
> > > > > > >
> > > > > > > You must print
> > > > > > >
> > > > > > > --
> > > > > > > Regards Ron de Bruin
> > > > > > > http://www.rondebruin.nl
> > > > > > >
> > > > > > >
> > > > > > > "Steven" <me@where.why> wrote in message
> > > > > > news:DhNoc.277$nh.131@newsfe6-gui.server.ntli.net...
> > > > > > > > Thanks Ron,
> > > > > > > > how could i test this without printing? if possible?
> > > > > > > >
> > > > > > > > Steve
> > > > > > > >
> > > > > > > > "Ron de Bruin" <rondebruin@kabelfoon.nl> wrote in message
> > > > > > > > news:%23lL7C6POEHA.540@TK2MSFTNGP11.phx.gbl...
> > > > > > > > > Hi Steven
> > > > > > > > >
> > > > > > > > > Try this
> > > > > > > > >
> > > > > > > > > Sub test()
> > > > > > > > > If Range("total1") > 0 Then ActiveSheet.PrintOut From:=1,
> > To:=1
> > > > > > > > > If Range("total2") > 0 Then ActiveSheet.PrintOut From:=2,
> > To:=2
> > > > > > > > > If Range("total3") > 0 Then ActiveSheet.PrintOut From:=3,
> > To:=3
> > > > > > > > > If Range("total4") > 0 Then ActiveSheet.PrintOut From:=4,
> > To:=4
> > > > > > > > > End Sub
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > --
> > > > > > > > > Regards Ron de Bruin
> > > > > > > > > http://www.rondebruin.nl
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > "Steven" <me@where.why> wrote in message
> > > > > > > > news:kELoc.118$6X5.92@newsfe1-win...
> > > > > > > > > > here's my situation, i have a workbook with many sheets
in
> > it,
> > > > each
> > > > > > > > sheet if
> > > > > > > > > > the default print shortcut button was used would print
to 4
> > > > pages of
> > > > > > A4
> > > > > > > > > > paper.
> > > > > > > > > >
> > > > > > > > > > the data on these sheets varies everyday, someday's only
1
> > page
> > > > per
> > > > > > > > sheet
> > > > > > > > > > would be full of data others 2, 3, or 4 etc. how could i
> > write a
> > > > > > macro
> > > > > > > > that
> > > > > > > > > > would be able to print only the needed pages?, each
page, if
> > it
> > > > > > contains
> > > > > > > > any
> > > > > > > > > > data would have a value in a totals cell.
> > > > > > > > > >
> > > > > > > > > > so i would need code along these lines
> > > > > > > > > >
> > > > > > > > > > Sheets("sheet1").Select
> > > > > > > > > > IF(OR(total1="",total1=0),"don't print","don't print")
ELSE
> > set
> > > > > > data1 =
> > > > > > > > TRUE
> > > > > > > > > > IF(OR(total2="",total2=0),"don't print","don't print")
ELSE
> > set
> > > > > > data2 =
> > > > > > > > TRUE
> > > > > > > > > > IF(OR(total3="",total3=0),"don't print","don't print")
ELSE
> > set
> > > > > > data3 =
> > > > > > > > TRUE
> > > > > > > > > > IF(OR(total4="",total4=0),"don't print","don't print")
ELSE
> > set
> > > > > > data4 =
> > > > > > > > TRUE
> > > > > > > > > >
> > > > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 1",
> > "don't
> > > > > > print")
> > > > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 2",
> > "don't
> > > > > > print")
> > > > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 3",
> > "don't
> > > > > > print")
> > > > > > > > > > IF(OR(data1 ="TRUE",data1="FALSE"),"Print Page 1 to 4",
> > "don't
> > > > > > print")
> > > > > > > > > >
> > > > > > > > > > Hope this helps to explain what im trying to do, and
someone
> > is
> > > > able
> > > > > > to
> > > > > > > > code
> > > > > > > > > > something that would work.
> > > > > > > > > >
> > > > > > > > > > Many thanks,
> > > > > > > > > > Steve
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > >
> > > > > --
> > > > >
> > > > > Dave Peterson
> > > > > ec35720@msn.com
> > >
> > > --
> > >
> > > Dave Peterson
> > > ec35720@msn.com
>
> -- 
>
> Dave Peterson
> ec35720@msn.com


0
me9665 (83)
5/16/2004 9:48:25 PM
Depends on what you mean by "look at".

If the total1, ..., total4 ranges are on different sheets, then it'll look at
them (are they worksheet level names or workbook level names?).

But this line:
ActiveSheet.PrintOut preview:=True, ...
means just the activesheet.




Steven wrote:
> 
> will it look at all sheets, only active or only ones listed in the macro?
> 
> Many thanks
> Steve
> 
> "Dave Peterson" <ec35720@msn.com> wrote in message
> news:40A7DDEB.F12E56D3@msn.com...
> > if total4 is bigger than 0, then print
> > if it's not, then check total3.  if that's bigger than 0, then print.
> > if it's not,....
> >
> > And so forth.
> >
> > You may want to test it against a small version of your workbook to see if
> it
> > works the way you want.
> >
> >
> >
<<snipped>>
-- 

Dave Peterson
ec35720@msn.com
0
ec35720 (10082)
5/17/2004 12:00:26 AM
maybe it would be easier for you to take a look at the workbook?

Steve

"Dave Peterson" <ec35720@msn.com> wrote in message
news:40A8009A.C520EF17@msn.com...
> Depends on what you mean by "look at".
>
> If the total1, ..., total4 ranges are on different sheets, then it'll look
at
> them (are they worksheet level names or workbook level names?).
>
> But this line:
> ActiveSheet.PrintOut preview:=True, ...
> means just the activesheet.
>
>
>
>
> Steven wrote:
> >
> > will it look at all sheets, only active or only ones listed in the
macro?
> >
> > Many thanks
> > Steve
> >
> > "Dave Peterson" <ec35720@msn.com> wrote in message
> > news:40A7DDEB.F12E56D3@msn.com...
> > > if total4 is bigger than 0, then print
> > > if it's not, then check total3.  if that's bigger than 0, then print.
> > > if it's not,....
> > >
> > > And so forth.
> > >
> > > You may want to test it against a small version of your workbook to
see if
> > it
> > > works the way you want.
> > >
> > >
> > >
> <<snipped>>
> -- 
>
> Dave Peterson
> ec35720@msn.com


0
me9665 (83)
5/17/2004 4:30:09 PM
What happened when you tried it?


Steven wrote:
> 
> maybe it would be easier for you to take a look at the workbook?
> 
> Steve
> 
> "Dave Peterson" <ec35720@msn.com> wrote in message
> news:40A8009A.C520EF17@msn.com...
> > Depends on what you mean by "look at".
> >
> > If the total1, ..., total4 ranges are on different sheets, then it'll look
> at
> > them (are they worksheet level names or workbook level names?).
> >
> > But this line:
> > ActiveSheet.PrintOut preview:=True, ...
> > means just the activesheet.
> >
> >
> >
> >
> > Steven wrote:
> > >
> > > will it look at all sheets, only active or only ones listed in the
> macro?
> > >
> > > Many thanks
> > > Steve
> > >
> > > "Dave Peterson" <ec35720@msn.com> wrote in message
> > > news:40A7DDEB.F12E56D3@msn.com...
> > > > if total4 is bigger than 0, then print
> > > > if it's not, then check total3.  if that's bigger than 0, then print.
> > > > if it's not,....
> > > >
> > > > And so forth.
> > > >
> > > > You may want to test it against a small version of your workbook to
> see if
> > > it
> > > > works the way you want.
> > > >
> > > >
> > > >
> > <<snipped>>
> > --
> >
> > Dave Peterson
> > ec35720@msn.com

-- 

Dave Peterson
ec35720@msn.com
0
ec35720 (10082)
5/17/2004 10:00:50 PM
Reply:

Similar Artilces:

PO amount different on PO Entry screen from printed PO
Hi, We have a problem that seems to happen every month. In the Purchase Order Entry window, the subtotal on this one particular PO is $590,776.35. However if we print the PO, the subtotal amount on the printed PO is only $472,451.66. The only seems to happen on random PO's and we can't figure out why. It's starting to annoy our Purchasing department... Ideas? Thanks, --Nathan Nathan, What version and service pack of GP? Are there PO's entered manually or imported? Is the PO report modified? Are there typically a lot of changes to the PO's that this happens to?...

Today Conditional Format
I have a column which calculated a date based on 3 working days from a date input into a diff column. What I want to do I have the calculated date appear bold if that date has passed based on the current date. For example if I input 01/08/11 the next column calculates 04/08/11 (3 working days). I want the caluclated date to appear bold when I open the spreadsheet on the 05/08/11 ro show the calculated date has passed. I can use conditional formatting but can't get the syntax right Regards Andy Win XP Pro Office 2010 Andy Roberts presented the following explanation : > I ha...

I want to print multi pages on one page.
I've tried going into set up and under page layout telling it to print 2 pages per sheet, but that doesn't work. Is there another way? If, by "multi-pages" you really mean multiple worksheets on one page that is not possible. You could add a 'summary' worksheet to combin your data and print that with the "fit to page" option checked on th Page Setup screen. Be careful with the 'fit to screen' as it can mak the printout unreadably small. Good Luck Bruc -- swatsp0 ----------------------------------------------------------------------- swatsp0p...

Printing Help
I know there should be an easy way to do this, but I have yet to figure it out. I have a 183 page report on school districts. I want to print all the information for one school district per page (or possibly two because a few of the larger districts might take up two pages.) On the report, I have one district per page or two and I could just print the whole thing but I don't want to. Is there a way to print a certain district? I don't want to just print page 42 and wonder what district that is. I want to print, let's say Spring School District, and only that page prints. Th...

Two Condition Vlookup?
I am currently trying to create a function that searches through an array for two exact column values which allows me to retrieve a third column value. For example: Type of Fruit Date Packaged Amount of Fruit Apples June 100 Oranges June 50 Apples July 75 Grapes July 50 In this example, I would be looking to retrieve the Amount of Fruit (Apples) that was packaged in July. I would be putt...

Print margins on incoming emails
When I print incoming emails my printer cuts off a fraction of the left margin. I cannot figure out how to correct the problem. Outlook Express uses the same print engine as Internet Explorer. For print size: IE | View | Text Size | Make adjustment. For margins: IE | File | Page Setup. Default setting is 0.75, (19mm), all around. -- Bruce Hagen MS-MVP [Mail] Imperial Beach, CA "Jonnah" <Jonnah@discussions.microsoft.com> wrote in message news:B4B38E7F-582C-4A9B-8041-7ABCF9A4107D@microsoft.com... > When I print incoming ema...

picture wont print correctly
Hello, I am trying to print a company logo in Publisher, its brown and black. It looks fine on the document and in print preview but when I print it only the brown portions of the logo are printed and they come out light blue. Please help ! MelissaYH <MelissaYH@discussions.microsoft.com> was very recently heard to utter: > Hello, I am trying to print a company logo in Publisher, its brown > and black. It looks fine on the document and in print preview but > when I print it only the brown portions of the logo are printed and > they come out light blue. Have you checked yo...

macro with F9
I want to a macro to insert the formula =TODAY() and then recalc it to make it a static result that represents the date as of the time the macro is run, not a dynamic formula that would change with each new day. I have recorded a macro to do this. If I run the macro & today is Aug 3, the correct result would be 08/03/2005, not the formula =TODAY(). However, if I run my macro tomorrow, Aug 4, the macro returns a result of 08/03/2005, because the code that resulted from my macro-record has a line in it, such as Select Active Cell. Active Cell = "08/03/2005." I would like ...

Need help with conditional formula (Excel 97)
Can anyone give me the correct syntax for the following formula: if A1 is blank, and B1 is more than zero, then display B1, otherwise display nothing (blank cell) Thank you JD =IF(AND(A1="",B1>0),B1,"") Success! -- met vriendelijke groetjes "Jake D" <JakeD@djhtend.com> schreef in bericht news:crkto4lv30u7uujv27ek8okr0us5t9oj10@4ax.com... > Can anyone give me the correct syntax for the following formula: > > if A1 is blank, and B1 is more than zero, then display B1, otherwise > display nothing (blank cell) > > Thank you > > ...

Query condition by date range
I'm trying to create a query to base a report from. I need it to return records within a date range that needs to be specified, as in specifying the beginning date and having the current date as the end date. A field is included in the query that has listed dates in the format mm/dd/yyyy. How would I write the criteria? I have part of it ready - [Please enter starting date:] . I know that's how you get the little question window. On Tue, 4 Dec 2007 14:51:00 -0800, silva wrote: > I'm trying to create a query to base a report from. I need it to return > records within a...

Outlook 2003: Attachment Icon doesn't print
All users in a subsidiary office share this attachment icon problem: they see the paper clip in the attachment field prior to opening the e-mail message, and they also see the icon in the opened e-mail (sometimes located below the subject line in the heading, and sometimes located in the body of the e-mail). When they print the message, the icon fails to appear. It will print when you print the message in Plain Text. For HTML it will be fixed in SP1 which is coming soon! -- Robert Sparnaaij [MVP-Outlook] www.howto-outlook.com Tips of the month: -Backup and Restore -Create an O...

Conditional formatting if condition of an if statement is true and a string value is displayed
Dear Experts: I got a nested 'IF'-Formula in an excel cell that returns nothing if the condition is false. I would like to conditionally format this cell with grey shading if the condition is true and a string value is displayed. How can this be achieved using excel conditional formating functionality ? Help is much appreciated. Thank you very much in advance. Regards, Andreas Let's say your doing this conditional formatting in cell K17. In conditional formatting (xl2003) choose the FormulaIs: option and enter: =$K$17<>"" choose your formatt...

Printing list of emails in Oulook Express
I am trying to find a way to print, an entire list of email reciepts, so I don't have to keep them. Can anyone help? >-----Original Message----- >I am trying to find a way to print, an entire list of email reciepts, so I=20 >don't have to keep them. Can anyone help? >. > These Newsgroups address issues regarding MS Office Outlook. Outlook Express is a component of Windows/Internet Explorer. Post your question where the OE gurus hang out: http://communities.microsoft.com/newsgroups/default.asp?icp=3DInternetExp= lorer ...

Print preview
Hi, I tried to print a particular repor with one employee only. It works here with preview: DoCmd.OpenReport "rptInvoice", acViewPreview, , "[tblInvoices].[ID] = " & Me.txtInvoiceID, acDialog However, if I don't preview it by DoCmd.OpenReport "rptInvoice", , , "[tblInvoices].[ID] = " & Me.txtInvoiceID, acDialog it then prints out all employee, any idea? In addition, in the preview, there is no print button or option for me to print, what property I should set to enable the print option in preview? ...

excel 2003
I've got a problem with excel 2003. When I select some sheets to print them in 1 print job, it splits the printjob to 2 seperate printjobs. This normaly is not a problem, but since I want to print to pdf, pdf-printer will regerate 2 files. Does anyone know how to solve this problem? I searched the internet allready, but I only found 1 solution. This is to set quality all to the same option, eg. all to 600 dpi. This solution only work for excel 97, but I tryed it anyway. Did not work :-( Some ideas? Maybe you can provide more details. I created a workbook with 4 worksheets. I select...

Conditional Field in Queries
Is there a way to make a field in a query conditional so that it only displays the value if the value is equal to something specifically set? Thanks. Nick Nick.Korynski@gmail.com wrote: > Is there a way to make a field in a query conditional so that it only > displays the value if the value is equal to something specifically > set? Thanks. > > Nick Explain "the value is equal to something specifically set". -- Rick Brandt, Microsoft Access MVP Email (as appropriate) to... RBrandt at Hunter dot com ...

How do i use Conditional formatting for 3+ conditions ?
I have a text box in a report which highlights in colour current members in a list of past and present member names. I have six types of current members that I want to highlight, but with conditional formatting I can only use 3 conditions in the members [Type] field. I have tried [Type]="Full member" Or "Life member" but the "Or" doesn't work ! Is there a way to do this ? thanks .. Roger CF is limited to 3 contitions, but you can use OR in those expressions. If you set Condition1 to Expression, you can use: ([Type] = "Full member") Or (...

Business card print prob
Hi to all I have asked this before but comp prob so lost info. I am trying to print a page with 10 business cards on it but as it prints the writing slips down the page; I have done all checks I can think of . thanks sandra This is a printer issue, especially inkjets. Your roller pickup may be faulty. Do you have a lever for heavier stock? -- Mary Sauer MSFT MVP http://office.microsoft.com/ http://msauer.mvps.org/ news://msnews.microsoft.com "Sandra Bodycoat" <sandybody@westnet.com.au> wrote in message news:42f88d5e$1@quokka.wn.com.au... > Hi to all > I have ask...

how to select paragraphs to be printed
how do i select various paragraphs on the same page to be printed i can only highlight one paragraph at a time many thanks While you can select non-contiguous selections by holding the CTRL key whilst making the selections, you cannot readily print such a selection from the print dialog. The following macro will however print it. Sub PrintSelected() Application.ScreenUpdating = False On Error GoTo Oops Selection.Copy Documents.Add Selection.Paste With ActiveDocument .PrintOut .Close wdDoNotSaveChanges End With Application.ScreenUpdating = True End Oops: MsgBo...

Printing "embedded" emails Outlook 2000
Some emails are sent with an Excel worksheet embedded in the text. The email is sent in html format. On some recipients pcs, the embeded worksheet will not print the worksheet but will print a box with a red X. The Outlook 2000 setup on all pcs is the same. What do I look for? ...

Conditional null value
Wondering if anyone can suggest a way to simplify the following code, which I’m using in the OnFormat event of a report. If Not IsNull(DLookup("[ICD2]", "EntryICDs", "[EntryNum] = " & Me! [PtAcct#])) Then Me![Field192] = Replace(DLookup("[ICD2]", "EntryICDs", "[EntryNum] = " & Me![PtAcct#]), ".", " ") End If If Not IsNull(DLookup("[ICD3]", "EntryICDs", "[EntryNum] = " & Me! [PtAcct#])) Then Me![Field194] = Replace(DLookup("[ICD...

Creating and printing file labels
Version: 2008 Operating System: Mac OS X 10.6 (Snow Leopard) I am trying to create a full sheet of different file labels. I can't bring up a document view that shows the template for the file labels for placement. Sorry, but you're going to have to provide a lot more descriptive detail about the problem in order for anyone to have a clue as to what that problem is. Exactly what are you trying to do as well as how you're going about it & what it is that's preventing your success. Make sure to specify your update levels of Office & OS X as well. Regards |:&g...

Excel print out problem
I have export several files from Lotus Notes to MS XP Excel files. When the click print preview those files at Excel, the file is OK. However, if the file is more then 1 page, the 1 st row will be repeated on everypage after printing. If I delete the 1 st row, then the 2 nd row will become the 1 st row and the print out is OK. I try to clear all the format in the cell and then re-created the format at excel file but when the file print out, it will keep repeating the 1 st row again. Any help? ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com...

outlook strange print problem
outlook 2003, sp3 all office updates applied on winxp machine with at least sp2, but i didn't check that part. when the user goes to print, they get a multiple page print job even though the email has only one page. at the top center of every page in roughly 16-18 pt font is P... and the very middle of the page prints a small small section of the email. the next page has another small small section of the email, and so on until all pages have printed. i have a PDF of what i mean if anyone needs to see visual proof of what is happening. the sections that are printing are coming from th...

Help with Conditional formatting with Dates
Hi there, I have a spreadsheet in which I have to monitor various dates which are in different columns (i.e. (1) Date Tender Released, (2) Date Company Selected, (3) Date Draft Contract Forwarded, (4) Date Contract Signed etc...). Would if be possible to Conditional Format and have diffirent ROWs highlighted for each individual Contracts (I have 300 running contracts running) every time a date is filled in these different columns: Initial Step (1) = Yellow (Call for Tender released) Step (2) = Blue (Company Selected) Step (3) = Brown (Contract under Process) Step (4) = Green (Contract Si...