group of worksheets in a workbook

G

GS

Johnnyboy5 formulated on Saturday :
Hi

how can I view (to check) which sheets have been included in a group ?

J

Loop through ActiveWindow.SelectedSheets for a list of sheetnames.
 
J

Johnnyboy5

Johnnyboy5 formulated on Saturday :




Loop through ActiveWindow.SelectedSheets for a list of sheetnames.

--
Garry

Free usenet access athttp://www.eternal-september.org
ClassicVB Users Regroup! comp.lang.basic.visual.misc

Hi

sorry not quite sure how to do that - is it a macro ?

Johnnny
 
C

Charabeuh

Hello !

You could use "ActiveWindow.SelectedSheets" in a macro to display the name
of the selected sheets.
In a VBA module paste the following code:

Public Sub Show_Selected_Sheets()
Dim Sh As Object, ShList As String

For Each Sh In ActiveWindow.SelectedSheets
ShList = ShList & Sh.Name & vbCrLf
Next Sh
MsgBox ShList

End Sub


_________________________
 
J

Johnnyboy5

Hello !

You could use "ActiveWindow.SelectedSheets" in a macro to display the name
of the selected sheets.
In a VBA module paste the following code:

Public Sub Show_Selected_Sheets()
Dim Sh As Object, ShList As String

For Each Sh In ActiveWindow.SelectedSheets
    ShList = ShList & Sh.Name & vbCrLf
Next Sh
MsgBox ShList

End Sub

_________________________

Wow - thanks - works a treat -

Johnnyboy
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top