Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 17
Default Follow on from Hiding 5 command buttons - Excel 97 prob now

Hi I got this from Tom which works great on my Office XP but does not work
on 97. I'm not really familiar with that! Is it that 97 does not recognise
these instructions? Help most respected!

Sub ABC()
Dim Obj As OLEObject
For Each Obj In Worksheets( _
"New Style 2006").OLEObjects
If TypeOf Obj.Object Is MSForms.CommandButton Then
Obj.Visible = Not Obj.Visible
End If
Next
End Sub



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Follow on from Hiding 5 command buttons - Excel 97 prob now

It was actually written and tested in Excel 97 when I posted it.

--
Regards,
Tom Ogilvy


"Karoo News" wrote in message
...
Hi I got this from Tom which works great on my Office XP but does not work
on 97. I'm not really familiar with that! Is it that 97 does not recognise
these instructions? Help most respected!

Sub ABC()
Dim Obj As OLEObject
For Each Obj In Worksheets( _
"New Style 2006").OLEObjects
If TypeOf Obj.Object Is MSForms.CommandButton Then
Obj.Visible = Not Obj.Visible
End If
Next
End Sub





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
Excel Command Buttons Newbee Excel Worksheet Functions 4 November 21st 06 07:03 PM
Control Tip Text on Excel Command Buttons Jason Zischke Excel Programming 1 January 10th 06 04:00 AM
Command buttons moving in Excel Tharkaway Excel Programming 3 March 14th 05 08:03 PM
Command buttons in Excel Harald Staff Excel Programming 0 September 7th 04 08:38 PM
Command buttons in Excel bigwheel[_2_] Excel Programming 0 September 7th 04 08:30 PM


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