Oppure

Loading
27/05/11 14:12
mash_mash
Mi son piantato chi mi dà una dritta :

nell'evento keypress di una textbox vorrei che quando digito una lettera questa sia scritta maiuscola.
La stessa etxt dovrebbe anche accettarmi oltre alle lettere i umeri ed il solo carettere - (meno).

aaa
27/05/11 17:08
gibra
Semplice:

Private Sub txt1_KeyPress(Index As Integer, KeyAscii As Integer)
KeyAscii = Asc(UCase$(Chr$(KeyAscii)))
End Sub

:D
aaa
01/06/11 7:10
albertking82
Ciao
Ti posto una possibile soluzione :

Private Sub text1_KeyPress(Index As Integer, KeyAscii As Integer)
if not isnumeric (text1.text) and text1.text <> "-" then exit sub
text1.text=UCase(text1.text)
End Sub
aaa