LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35
Default GroupName for OptionButton

I have a sheet that has many OptionButtons, I have another shhet in the same
workbook that has the same optionbuttons. Since I just copied the option
buttons from 1 page to another, each sheets group names are the same.

So I need to go through each OptionButton on the sheet and change the
GroupName to the sheet name And groupName.

ie: sheet1 has 3 option buttons grouped together named 1.1
I need to change all 3 option buttons GroupName to Sheet11.1
I have hundreds of groups like this so I need the VB to do the work.

Thank you!!!
This is what I have so far but doesn't work...

Sub FixButtons()

Dim shp As OptionButton
Dim strButName As String

For Each shp In Sheets(Sheet1).OptionButton
strButName = shp.GroupName
shp.GroupName = "Sheet1" + strButName
Next shp

End Sub

Error is "Object doesn't support this Property or method"
 
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
for each optionbutton masterphilch Excel Programming 1 September 21st 05 05:37 PM
How to referance a GroupName Garry[_7_] Excel Programming 3 October 5th 04 01:24 PM
Better Way to Use OptionButton [email protected] Excel Programming 0 September 1st 04 07:18 PM
Better Way to Use OptionButton [email protected] Excel Programming 4 September 1st 04 07:04 PM
GroupName Paul Excel Programming 2 December 4th 03 11:33 AM


All times are GMT +1. The time now is 07:19 AM.

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

About Us

"It's about Microsoft Excel"