Textbox in userform

S

shaharul

My problem is

Say i have 5 textbox consisting number value in user form
1 is master textbox and the other four are the breakdown of the master
How do i automatically check that total of the value of the other fou
tsxtbox equal to value in master textbox.
How do i change the variant type of the value entered in textbox t
integer type?

Thank you in advance for all the Excel Master out there
 
B

Bob Phillips

If Cint(TextBox1.Text) = Cint(TextBox2.Text) + _
Cint(TextBox3.Text) + _
Cint(TextBox4.Text) + _
Cint(TextBox5.Text)

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
J

Jim Rech

I think you posted to the wrong conversation.

--
Jim Rech
Excel MVP
| Master Bob,
|
| Thank you for the tips. Just wonder what is "Cint" for?
|
|
| ---
|
|
 
Top