Make asterisk appear in textbox when hitting enter? (1 Viewer)

Jenny Peters

Registered User.
Local time
Today, 08:27
Joined
Sep 16, 2001
Messages
14
How can I make an asterisk appear while typing in a text box when I press enter, and also go to the next line.

The textbox is actually set as a memo box in my table, and I want to be able to have an asterisk appear after I press the enter key.

Any thoughts?

Thanks,

jenny
 

Mile-O

Back once again...
Local time
Today, 08:27
Joined
Dec 10, 2002
Messages
11,316
PHP:
Private Sub txtData_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then txtData = txtData + "*"
End Sub

13 is the ASCII value for Return and Enter.

As for going to the next line, I'm not too sure if this can be done but yu could try:

PHP:
Private Sub txtData_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then txtData = txtData + "*" & vbCrLf
End Sub
 

Jenny Peters

Registered User.
Local time
Today, 08:27
Joined
Sep 16, 2001
Messages
14
Your suggestion does add the asterisk, but doesn't seem to move down a line.

What else can be done?

Thanks,

Jenny
 

Users who are viewing this thread

Top Bottom