Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 33
Default how to do for each worksheet in workbook exept one sheet??

this is part of my source code

For Each sh In ActiveWorkbook.Worksheets
sh.Range("b7").AutoFilter field:=1, Criteria1:="<",
visibledropdown:=False
Next

I want to use this but worksheet("overview") may not participate in
the" for each" procedure
something with exit for?

thankx

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 290
Default how to do for each worksheet in workbook exept one sheet??

Matthias,

This is something like what I use at the moment


Dim wks As Worksheet
Set ActSheet = ActiveSheet
overview.activate
For Each wks In ActSheet.Parent.Worksheets
If wks.Name < ActSheet.Name Then
'do nothing
Else
For Each sh In ActiveWorkbook.Worksheets
sh.Range("b7").AutoFilter field:=1, Criteria1:="<",
visibledropdown:=False
Next


HTH

Duncan

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 290
Default how to do for each worksheet in workbook exept one sheet??

ooops,

miss out your for each, i just copied your code and pasted it in.

I think there is a better way though.........................

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default how to do for each worksheet in workbook exept one sheet??

For Each sh In ActiveWorkbook.Worksheets
If sh.Name < "overview" Then
sh.Range("b7").AutoFilter field:=1, _
Criteria1:="<", _
visibledropdown:=False
End If
Next

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"matthias" wrote in message
oups.com...
this is part of my source code

For Each sh In ActiveWorkbook.Worksheets
sh.Range("b7").AutoFilter field:=1, Criteria1:="<",
visibledropdown:=False
Next

I want to use this but worksheet("overview") may not participate in
the" for each" procedure
something with exit for?

thankx



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 33
Default how to do for each worksheet in workbook exept one sheet??

perfect guys!!! thanks



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
Duplicating Worksheet to 20 sheet workbook Steve Excel Discussion (Misc queries) 0 September 28th 06 11:17 PM
copy data from one worksheet to identical sheet in different workbook akid12 Excel Discussion (Misc queries) 2 July 6th 05 02:55 AM
EXCEL: Find data in worksheet and create a new sheet in same workbook Peacce Dog Excel Programming 3 November 18th 04 08:05 PM
Excel2000: Copy all exept data Arvi Laanemets Excel Programming 1 May 11th 04 03:31 PM
My workbook doesn't works on no other PC exept mine.... Keith Willshaw Excel Programming 1 August 1st 03 04:46 PM


All times are GMT +1. The time now is 06:24 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"