By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,495 Members | 1,225 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,495 IT Pros & Developers. It's quick & easy.

Need to make shift-enter behave like control-enter

P: n/a
Client's fingers have been well trained on another application to wrap
lines by hitting shift-enter, and wants the same in Access application.

Changing "enter key behavior" for controls is not acceptable, because
same client's fingers automatically hit Enter (instead of Tab) to move
to the next field.

How to make shift-enter behave like control-enter? I've tried various
combinations code in Autokeys, Key Preview, Key Down, Key Up, and Key
Press, with no luck.

Any solutions out there? (Please don't post guesses. I already have
lots of those.)

pemigh

Jun 2 '06 #1
Share this Question
Share on Google+
2 Replies


P: n/a
pemigh wrote:
Client's fingers have been well trained on another application to wrap
lines by hitting shift-enter, and wants the same in Access application.

Changing "enter key behavior" for controls is not acceptable, because
same client's fingers automatically hit Enter (instead of Tab) to move
to the next field.

How to make shift-enter behave like control-enter? I've tried various
combinations code in Autokeys, Key Preview, Key Down, Key Up, and Key
Press, with no luck.

Any solutions out there? (Please don't post guesses. I already have
lots of those.)
That's a good way to not get responses. Kinda snooty, standoffish,
F*ck-offish. The advice given here is free of charge. Use your
attitude if you are paying for it. I'm giving you the benefit of the
doubt and providing a possible kludge solution.
pemigh


Try this. "Notes" is the name of my memo field.

Private Sub Notes_KeyUp(KeyCode As Integer, Shift As Integer)
If KeyCode = 13 And Shift = 1 Then
Dim lngLen As Long
Me.Notes = Me.Notes.Text & vbNewLine
lngLen = Len(Me.Notes.Text)
Me.Notes.SelStart = lngLen
Me.Notes.SelLength = 0
End If
End Sub

It's kinda funky as it pops to the first char and then goes to the last.
Jun 2 '06 #2

P: n/a
> It's kinda funky as it pops to the first char and then goes to the last.

That's a completely tolerable level of funk. But the code doesn't
behave well if you're trying to wrap a line in the middle of existing
text.

Also, I'm looking for a global solution (aren't we all?!) rather than a
control-by-control solution.

Thanks for the input!

PEmigh

Jun 6 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.