Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 33
Default check box interaction

I'd like to use a check box that will cause a couple of objects on a form
to alternate between visible and not visible. In other words, when the
check box is checked, I want a couple of parameters to be accessible, but
when the check box is unchecked, I don't want the parameters viewable. Can
a check box accomplish this, or am I confined to using a command button or
a toggle button?

Thanks.

Smokii
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,758
Default check box interaction

You could hide those other controls or you could even just disable them.

Option Explicit
Private Sub CheckBox1_Click()

Me.TextBox1.Enabled = Me.CheckBox1.Value
Me.CommandButton1.Enabled = Me.CheckBox1.Value
Me.CommandButton2.Enabled = Not (Me.CheckBox1.Value)
Me.Label1.Visible = Me.CheckBox1.Value

End Sub

(I just plopped a couple of controls on a userform and chose .enabled/.visible
at random.)



smokiibear wrote:

I'd like to use a check box that will cause a couple of objects on a form
to alternate between visible and not visible. In other words, when the
check box is checked, I want a couple of parameters to be accessible, but
when the check box is unchecked, I don't want the parameters viewable. Can
a check box accomplish this, or am I confined to using a command button or
a toggle button?

Thanks.

Smokii


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 33
Default check box interaction

Awesome....didn't know I could add "_click" option to the check box.
Thanks again, Dave

Smokii

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,758
Default check box interaction

Take a look at the code window for your form.

At the top of that window, you'll see two dropdowns. If you let your cursor
linger over the left hand dropdown, you'll see a tooltip of "Object". Use the
dropdown to select the object you want.

If you let your cursor linger over the right hand dropdown, you'll see
"Procedure".

If you look at the dropdown options for that object, you'll see all the
procedures you can choose from.



smokiibear wrote:

Awesome....didn't know I could add "_click" option to the check box.
Thanks again, Dave

Smokii


--

Dave Peterson
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
how set up regression for interaction? Arun Excel Discussion (Misc queries) 1 August 28th 06 12:10 PM
Excel and web interaction Scott Excel Discussion (Misc queries) 0 November 13th 05 07:11 PM
Interaction between worksheets teresa Excel Programming 1 December 1st 04 10:22 AM
Web interaction Nigel[_6_] Excel Programming 3 February 20th 04 08:34 AM
UserForm Interaction Bob Phillips[_5_] Excel Programming 0 September 22nd 03 08:12 PM


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