Posted: Mon Dec 03, 2012 5:27 pm Post subject: Why does this happen
When i program in VB 2008 and want to get user input it makes me put CInt infront of the Val()
widthA = CInt(Val(Me.txtBoxWidth.Text))
if i do not put the CInt i get a run time error and when i tell my teacher about this he said it should not be doing that because at my school computer it does not require CInt only on my computer.
Posted: Mon Dec 03, 2012 7:30 pm Post subject: RE:Why does this happen
likely because the input from a textbox is treated as a string (words), and you'd need to explicitly convert it to an integer (numbers) before use.