Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
dan dan is offline
external usenet poster
 
Posts: 41
Default clear option buttons **MACRO TWEAK**

Hello, I have the current macro assigned to clear the contents of
unlocked cells. What I would like to do is also include the clearing
of 2 Option Buttons as well.

Thanks for your assistance!

Private Sub CommandButton1_Click()
Dim cell As Range
For Each cell In ActiveSheet.UsedRange
If cell.Locked = False Then cell.MergeArea.ClearContents
Next
End Sub

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,726
Default clear option buttons **MACRO TWEAK**

activesheet.optionButtons("Option Button 1").value=0

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Dan" wrote in message
ups.com...
Hello, I have the current macro assigned to clear the contents of
unlocked cells. What I would like to do is also include the clearing
of 2 Option Buttons as well.

Thanks for your assistance!

Private Sub CommandButton1_Click()
Dim cell As Range
For Each cell In ActiveSheet.UsedRange
If cell.Locked = False Then cell.MergeArea.ClearContents
Next
End Sub




  #3   Report Post  
Posted to microsoft.public.excel.programming
dan dan is offline
external usenet poster
 
Posts: 41
Default clear option buttons **MACRO TWEAK**

On Feb 16, 3:34 pm, "Bob Phillips" wrote:
activesheet.optionButtons("Option Button 1").value=0

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"Dan" wrote in message

ups.com...



Hello, I have the current macro assigned to clear the contents of
unlocked cells. What I would like to do is also include the clearing
of 2 Option Buttons as well.


Thanks for your assistance!


Private Sub CommandButton1_Click()
Dim cell As Range
For Each cell In ActiveSheet.UsedRange
If cell.Locked = False Then cell.MergeArea.ClearContents
Next
End Sub- Hide quoted text -


- Show quoted text -


Thanks. Where would I encorporate this command into the macro?

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,726
Default clear option buttons **MACRO TWEAK**

Depends when you want it cleared, but I would guess after the Next
statement.

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Dan" wrote in message
ups.com...
On Feb 16, 3:34 pm, "Bob Phillips" wrote:
activesheet.optionButtons("Option Button 1").value=0

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my
addy)

"Dan" wrote in message

ups.com...



Hello, I have the current macro assigned to clear the contents of
unlocked cells. What I would like to do is also include the clearing
of 2 Option Buttons as well.


Thanks for your assistance!


Private Sub CommandButton1_Click()
Dim cell As Range
For Each cell In ActiveSheet.UsedRange
If cell.Locked = False Then cell.MergeArea.ClearContents
Next
End Sub- Hide quoted text -


- Show quoted text -


Thanks. Where would I encorporate this command into the macro?



  #5   Report Post  
Posted to microsoft.public.excel.programming
dan dan is offline
external usenet poster
 
Posts: 41
Default clear option buttons **MACRO TWEAK**

On Feb 17, 3:11 am, "Bob Phillips" wrote:
Depends when you want it cleared, but I would guess after the Next
statement.

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"Dan" wrote in message

ups.com...



On Feb 16, 3:34 pm, "Bob Phillips" wrote:
activesheet.optionButtons("Option Button 1").value=0


--
---
HTH


Bob


(there's no email, no snail mail, but somewhere should be gmail in my
addy)


"Dan" wrote in message


roups.com...


Hello, I have the current macro assigned to clear the contents of
unlocked cells. What I would like to do is also include the clearing
of 2 Option Buttons as well.


Thanks for your assistance!


Private Sub CommandButton1_Click()
Dim cell As Range
For Each cell In ActiveSheet.UsedRange
If cell.Locked = False Then cell.MergeArea.ClearContents
Next
End Sub- Hide quoted text -


- Show quoted text -


Thanks. Where would I encorporate this command into the macro?- Hide quoted text -


- Show quoted text -


Cool. 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
TRUE/FALSE MACRO using Option Buttons Jase Excel Discussion (Misc queries) 1 March 28th 08 09:15 PM
Option Buttons with macro and working with 2 workbooks Ren Excel Programming 0 July 26th 06 08:11 PM
Option buttons: How to get the selected option from a group? naddad Excel Programming 5 December 21st 05 05:09 PM
Can someone please tweak my Macro? Wibs Excel Discussion (Misc queries) 3 December 15th 05 05:10 PM
No control for option buttons, invisible macro?? Steve[_77_] Excel Programming 2 April 13th 05 02:38 PM


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