PC Review


Reply
Thread Tools Rate Thread

caption of Triplestate buttons

 
 
=?Utf-8?B?I0RJVi8w?=
Guest
Posts: n/a
 
      18th Sep 2007
I can change the caption of a ToggleButton with a simple

If ToggleButton1 = False Then
ToggleButton1.Caption = "False"
ElseIf ToggleButton1 = True Then
ToggleButton1.Caption = "True"
End If

But if I enable Triplestate I can't get a different caption for "Null".
The help file says that triplestate controls don't generate click events.
So how can I get a new caption as well as just the greyed out "False"
caption ?

--
David M
WinXP - Office2003 (Italian)
 
Reply With Quote
 
 
 
 
Mike Fogleman
Guest
Posts: n/a
 
      18th Sep 2007
With the Change Event:

Private Sub ToggleButton1_Change()
If IsNull(ToggleButton1.Value) Then
ToggleButton1.Caption = "Value is Null"
ElseIf ToggleButton1.Value = False Then
ToggleButton1.Caption = "Value is False"
ElseIf ToggleButton1.Value = True Then
ToggleButton1.Caption = "Value is True"
End If
End Sub

Mike F
"#DIV/0" <(E-Mail Removed)> wrote in message
news:AB6A6E49-5DAC-4D2F-9985-(E-Mail Removed)...
>I can change the caption of a ToggleButton with a simple
>
> If ToggleButton1 = False Then
> ToggleButton1.Caption = "False"
> ElseIf ToggleButton1 = True Then
> ToggleButton1.Caption = "True"
> End If
>
> But if I enable Triplestate I can't get a different caption for "Null".
> The help file says that triplestate controls don't generate click events.
> So how can I get a new caption as well as just the greyed out "False"
> caption ?
>
> --
> David M
> WinXP - Office2003 (Italian)



 
Reply With Quote
 
=?Utf-8?B?I0RJVi8w?=
Guest
Posts: n/a
 
      18th Sep 2007
Thanks Mike
--
David M
WinXP - Office2003 (Italian)


"Mike Fogleman" wrote:

> With the Change Event:
>
> Private Sub ToggleButton1_Change()
> If IsNull(ToggleButton1.Value) Then
> ToggleButton1.Caption = "Value is Null"
> ElseIf ToggleButton1.Value = False Then
> ToggleButton1.Caption = "Value is False"
> ElseIf ToggleButton1.Value = True Then
> ToggleButton1.Caption = "Value is True"
> End If
> End Sub
>
> Mike F
> "#DIV/0" <(E-Mail Removed)> wrote in message
> news:AB6A6E49-5DAC-4D2F-9985-(E-Mail Removed)...
> >I can change the caption of a ToggleButton with a simple
> >
> > If ToggleButton1 = False Then
> > ToggleButton1.Caption = "False"
> > ElseIf ToggleButton1 = True Then
> > ToggleButton1.Caption = "True"
> > End If
> >
> > But if I enable Triplestate I can't get a different caption for "Null".
> > The help file says that triplestate controls don't generate click events.
> > So how can I get a new caption as well as just the greyed out "False"
> > caption ?
> >
> > --
> > David M
> > WinXP - Office2003 (Italian)

>
>
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Caption on command buttons shrinking =?Utf-8?B?TS5NdXN0b2U=?= Microsoft Excel Programming 0 9th Sep 2007 03:10 AM
Move Caption Buttons =?Utf-8?B?a2F0ZWJpZ2dlcg==?= Windows XP General 5 17th Feb 2005 08:00 PM
Sort buttons by caption? David Microsoft Excel Programming 3 26th Dec 2003 07:54 PM
Solustion Strange Fonts on Caption Buttons Randy Microsoft Windows 2000 New Users 2 5th Dec 2003 08:03 PM
Change Fonts on Caption Buttons Randy Microsoft Windows 2000 New Users 2 23rd Nov 2003 02:00 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:52 PM.