Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Junior Member
 
Posts: 2
Default Clear Contents and Checkboxes Button

Hello,

I am trying to create a button in that will clear contents of E5:E8 and and also clear all checkboxes (located in D5:D8) on the sheet. I have the codes below but can't seem to get them to work together. Additionally, I cannot recall whether I created the checkboxes with activex or form.

Private Sub CommandButton1_Click()
Range("E5:E8").ClearContents
Sub clearcheck()
ActiveSheet.CheckBoxes.Value = False
End Sub
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,872
Default Clear Contents and Checkboxes Button

Hi Chris,

Am Tue, 21 Jun 2016 17:44:16 +0100 schrieb chrisparker3268:

I am trying to create a button in that will clear contents of E5:E8 and
and also clear all checkboxes (located in D5:D8) on the sheet. I have
the codes below but can't seem to get them to work together.
Additionally, I cannot recall whether I created the checkboxes with
activex or form.


your checkboxes have refer to column T range T5:T8.
Try:

Sub Test()
Range("E5:E8").ClearContents
Range("T5:T8") = False
End Sub


Regards
Claus B.
--
Windows10
Office 2016
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
Clear certain checkboxes Arlen Excel Discussion (Misc queries) 4 May 20th 10 11:42 PM
using button to clear contents Charlie Excel Worksheet Functions 2 December 10th 09 03:13 AM
Clear Checkboxes fak119 Excel Discussion (Misc queries) 1 March 22nd 07 05:43 PM
Clear cell contents with a button KFC / A&W Boy Excel Worksheet Functions 1 March 7th 05 10:39 AM
Clear All Checkboxes? Brad Excel Programming 3 January 11th 05 08:58 PM


All times are GMT +1. The time now is 09:26 AM.

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

About Us

"It's about Microsoft Excel"