validating text in box

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • lenin42001
    New Member
    • Jan 2007
    • 29

    #1

    validating text in box

    Help i've just done a basic calculator with three textboxes a label & a button, basically when you add a number in textbox1 to the one in textbox2 it appears in textbox3 .........now the question asks to check if the user has typed in something appropriate . It says double click on txtnum1 use right hand list box to find Validating( ) event, then modify event stub so it looks like this
    If Not IsNumeric(txtNu m1.text) Then e.Cancel =True End if

    Please where does the last data go to ? Where is the validating event. I've tried to put it in the text box but it doesnt work. Where is Validating on the right hand side. I can't see it anywhere....... ...All help gratefully recieved.

    Help one of your people tried to help, they suggested pulling down the validating box & entering date. I pulled down in the second row as pointed out, but it says something about a boolean do you have to eraze this.?..what about the end sub do you have to change this for END IF or do you keep it.......
    When I tried to compile it i got a run time error.......... .....
  • Killer42
    Recognized Expert Expert
    • Oct 2006
    • 8429

    #2
    Look up the online help from VB, and study how to insert code in an event procedure for a control. In this case, the Validating event.

    Comment

    Working...