ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   tick boxes on userforms (https://www.excelbanter.com/excel-programming/318980-tick-boxes-userforms.html)

Mark \(InWales\)[_17_]

tick boxes on userforms
 
Hello All

I have a userform with an array filled ListBox. What I am trying to do is
set the CheckBox value to true if the item in the array has a total
associated with it. So if you select item1 in the ListBox and enter a total
via a TextBox for item1 then CheckBox1=true assuming the user doesn't exit
the UserForm.

Any help would be greatly appreciated especially if this could be done using
a loop instead of adding each checkbox and the associated If statements!

Mark



Dmoney

tick boxes on userforms
 
u can check for and set the checkbox's desired condition
with the textbox change event for exmpl:

Private Sub TextBox1_Change()
If TextBox1.Value < "" Then
CheckBox1.Value = True
Else: CheckBox1.Value = False
End If

End Sub
-----Original Message-----
Hello All

I have a userform with an array filled ListBox. What I

am trying to do is
set the CheckBox value to true if the item in the array

has a total
associated with it. So if you select item1 in the

ListBox and enter a total
via a TextBox for item1 then CheckBox1=true assuming the

user doesn't exit
the UserForm.

Any help would be greatly appreciated especially if this

could be done using
a loop instead of adding each checkbox and the associated

If statements!

Mark


.


Mark \(InWales\)[_18_]

tick boxes on userforms
 
Thanks DMoney for your help
"DMoney" wrote in message
...
u can check for and set the checkbox's desired condition
with the textbox change event for exmpl:

Private Sub TextBox1_Change()
If TextBox1.Value < "" Then
CheckBox1.Value = True
Else: CheckBox1.Value = False
End If

End Sub
-----Original Message-----
Hello All

I have a userform with an array filled ListBox. What I

am trying to do is
set the CheckBox value to true if the item in the array

has a total
associated with it. So if you select item1 in the

ListBox and enter a total
via a TextBox for item1 then CheckBox1=true assuming the

user doesn't exit
the UserForm.

Any help would be greatly appreciated especially if this

could be done using
a loop instead of adding each checkbox and the associated

If statements!

Mark


.





All times are GMT +1. The time now is 01:15 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com