Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 39
Default toggle box print if value is true

I have a toggle box set up with the following formula

Private Sub ToggleButton10_Click()
With Me.ToggleButton10
If .Value = False Then
.ForeColor = &H0
Else
.ForeColor = &HFFFFFF
End If
End With
End Sub

Is it possible to make the toggle box print only if the value is true?
Thanks in advance for any help
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default toggle box print if value is true

Hi John,

Try:

Private Sub ToggleButton1_Click()

With Me.ToggleButton1
If .Value = False Then
.ForeColor = &H0
.PrintObject = False
Else
.ForeColor = &HFFFFFF
.PrintObject = True
End If
End With

End Sub


--

---
Regards,
Norman



"John Davies" wrote in message
...
I have a toggle box set up with the following formula

Private Sub ToggleButton10_Click()
With Me.ToggleButton10
If .Value = False Then
.ForeColor = &H0
Else
.ForeColor = &HFFFFFF
End If
End With
End Sub

Is it possible to make the toggle box print only if the value is true?
Thanks in advance for any help



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
What's the best way to toggle between true and false in Excel? Hiall, My excel work involves a lot of toggling between true and false (booleantypes) ... and it's very repetitive... Is there a way to select a bunch ofcells, and press a key short-cu LunaMoon Excel Discussion (Misc queries) 9 July 29th 08 12:28 AM
have toggle buttons but everytime print preview buttons move TinSandhu Excel Discussion (Misc queries) 1 October 11th 06 02:57 PM
Checkbox toggle true/false Donkin Excel Programming 3 June 2nd 05 09:37 AM
Print Orientation Toggle Alan Tolkoff Excel Programming 2 December 14th 04 01:30 AM
Toggle True/False in a cell Dave Peterson[_3_] Excel Programming 2 October 10th 03 03:05 AM


All times are GMT +1. The time now is 07:34 PM.

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"