B
Brad
Thanks for taking the time to read my question.
I am making a form that is a keyboard and I want to have an Enter button
that acts like a carriage return chr(13) or chr(10). Using 13 or 10 does not
seem to work for me. The values I type are going into a text box that is data
type Memo.
Any ideas how I can accomplish this?
Brad
CODE:
I pass TheLetter from the letters on the keyboard cmdA_Click for example. It
checks if it's supposed to be CAPS or not and then passes the proper value to
the function. The Enter key passes "Enter".
Function AddText(TheLetter As Variant)
If Me.Notes = "" Then
If TheLetter = "Enter" Then
Me.Notes = Chr(13) 'trying to add a carriage return here
Else
Me.Notes = TheLetter
If Me.chkShift = True Then
Me.chkShift = False
ChangeCase
End If
End If
Else
If TheLetter = "Enter" Then
Me.Notes = Me.Notes & Chr(13) 'trying to add a carriage return
here
Else
Me.Notes = Me.Notes & TheLetter
End If
If Me.chkShift = True Then
Me.chkShift = False
ChangeCase
End If
End If
End Function
I am making a form that is a keyboard and I want to have an Enter button
that acts like a carriage return chr(13) or chr(10). Using 13 or 10 does not
seem to work for me. The values I type are going into a text box that is data
type Memo.
Any ideas how I can accomplish this?
Brad
CODE:
I pass TheLetter from the letters on the keyboard cmdA_Click for example. It
checks if it's supposed to be CAPS or not and then passes the proper value to
the function. The Enter key passes "Enter".
Function AddText(TheLetter As Variant)
If Me.Notes = "" Then
If TheLetter = "Enter" Then
Me.Notes = Chr(13) 'trying to add a carriage return here
Else
Me.Notes = TheLetter
If Me.chkShift = True Then
Me.chkShift = False
ChangeCase
End If
End If
Else
If TheLetter = "Enter" Then
Me.Notes = Me.Notes & Chr(13) 'trying to add a carriage return
here
Else
Me.Notes = Me.Notes & TheLetter
End If
If Me.chkShift = True Then
Me.chkShift = False
ChangeCase
End If
End If
End Function