Link to home
Start Free TrialLog in
Avatar of DavidH7470
DavidH7470Flag for United States of America

asked on

Excel 2003 VB Variable used in Controls of user froms.

Hello,

I am creating a user form in Excel that has a number of text boxes that a user enters data into. Some are to be numeric only.  If a user enters non-numeric data in the box there is code to catch that and return a zero value and lets the user know.  Rather than right the code for each box I assign a integer variable to the code on each TextBox and pass that along to a public function that uses that to create a variable representing the TextBox control name.  ie  It takes "TextBox" and combines it with 1, 2, 3, etc and uses that as the control name to run the routine.  It fails please help.  Sample is attached. Text-Box-Variable.xls
ASKER CERTIFIED SOLUTION
Avatar of StephenJR
StephenJR
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of DavidH7470

ASKER

Great Thank you.