Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 122
Default problem with..end with selection

Hi experts,

i have this simple code but it does not seem to work.

With Sheets("Output")
.Visible = True
.Range("A1:F56").Select
.PrintPreview
.Visible = False
End With

I just want a preview of the selected range("A1:F56")......

can anybody help me please ?
Thanks,
Pierre


--
Message posted via http://www.officekb.com
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default problem with..end with selection

Hi Pierre,

I thinks that this might be what you want

With Sheets("Output")
.Visible = True
.PageSetup.PrintArea = "$A$1:$F$27"
.PrintPreview
.Visible = False
End With


--

HTH

RP
(remove nothere from the email address if mailing direct)


"Pierre via OfficeKB.com" <u13950@uwe wrote in message
news:569d8f80c5dda@uwe...
Hi experts,

i have this simple code but it does not seem to work.

With Sheets("Output")
.Visible = True
.Range("A1:F56").Select
.PrintPreview
.Visible = False
End With

I just want a preview of the selected range("A1:F56")......

can anybody help me please ?
Thanks,
Pierre


--
Message posted via http://www.officekb.com



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default problem with..end with selection

Hi,

Add the line no 3 to the code.

- Mika

With Sheets("Output")
.Visible = True
.Select
.Range("A1:F56").Select
.PrintPreview
.Visible = False
End With

"Pierre via OfficeKB.com" <u13950@uwe wrote in message
news:569d8f80c5dda@uwe...
Hi experts,

i have this simple code but it does not seem to work.

With Sheets("Output")
.Visible = True
.Range("A1:F56").Select
.PrintPreview
.Visible = False
End With

I just want a preview of the selected range("A1:F56")......

can anybody help me please ?
Thanks,
Pierre


--
Message posted via http://www.officekb.com



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 122
Default problem with..end with selection

thanks Bob...again!
Your code works fine !
Pierre

Bob Phillips wrote:
Hi Pierre,

I thinks that this might be what you want

With Sheets("Output")
.Visible = True
.PageSetup.PrintArea = "$A$1:$F$27"
.PrintPreview
.Visible = False
End With

Hi experts,

[quoted text clipped - 12 lines]
Thanks,
Pierre



--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200510/1
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
Selection problem Just wondering Excel Discussion (Misc queries) 2 November 6th 09 01:54 AM
Selection problem with recorder brian Excel Discussion (Misc queries) 2 September 19th 06 12:24 AM
Range selection problem Brian Excel Programming 3 February 4th 05 01:56 PM
range selection problem derekc[_12_] Excel Programming 2 June 18th 04 04:41 PM
selection.pastespecial problem rleonard[_2_] Excel Programming 1 May 31st 04 10:56 AM


All times are GMT +1. The time now is 12:02 AM.

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"