Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

sum data in combo box

Status
Not open for further replies.

Zorro1265

Technical User
Nov 14, 2000
181
US
I have a combo box with the following code attached to a command button.

Me!TextBoxFemScore = age.Column(3) + ldl.Column(3) + hdl.Column(3) + bp.Column(3) + Diabetes.Column(3) + smoker.Column(3)

This is on the click event. What I am trying to do is add the data from each combo box together. What I end up with is a string of numbers.

For example

1+2+3+4 should equal 10
I get 1234.

Any ideas on how to fix this? Zorro
 
Hi,

Maybe you should try :

Me!TextBoxFemScore = val(age.Column(3)) + val(ldl.Column(3))+ val(hdl.Column(3)) + val(bp.Column(3)) + val(Diabetes.Column(3)) + val(smoker.Column(3))


hope it helps!

Salvatore Grassagliata
GrassagliataS@hotmail.com
 
Thats it!

Thanks so much I never thought of that! Zorro
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top