(from earlier thread)
___________________________________________________
Private Sub Text2_KeyPress(KeyAscii As Integer)
Dim num As Integer num = Val(Text2.Text)
if KeyAscii = 13 Then
Label1.Caption = num + 5
End If
End Sub
_________________________________
Megatron

________________________________________
'm sorry to disagree, but while it is poor code, the line num = text2.text will work just fine as long as the string is a numeric character or characters.
__________________ Marty


>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
This is what you said in response to Megatron.
All I want to know is WHY is it poor code? How could you make in "unpoor?"

thanks