Enter key

  • Thread starter Thread starter Claudie Bouzy
  • Start date Start date
Claudie Bouzy said:
How do you set the enter key to move from one field to
another field?

Set the Form's keypreview property = True and handle the Form's keypress
event.
 
Armin Zingler said:
Set the Form's keypreview property = True and handle the Form's
keypress event.

I forgot: In the event handler, call SelectNextControl:


Private Sub Form1_KeyDown( _
ByVal sender As Object, _
ByVal e As System.Windows.Forms.KeyEventArgs) _
Handles MyBase.KeyDown

If e.KeyCode = Keys.Enter Then
Me.SelectNextControl( _
Me.ActiveControl, True, True, True, True _
)
e.Handled = True
End If

End Sub
 
Hi Herfried,

It's actually standard in many systems for the Enter key to move from
field to field. (and has been for longer than you've been alive!)

<Now> who's being Windows-centric, lol. ;-))

Regards,
Fergus
 
* "Fergus Cooney said:
It's actually standard in many systems for the Enter key to move from
field to field. (and has been for longer than you've been alive!)

We are talking about development of applications using _Windows_ forms.
<Now> who's being Windows-centric, lol. ;-))

ROFL
 
Hi Fergus,

But I can remember me long discussions with programmers who said that was
not nice.

It was easy to overcome of course, you went with such a program to a user
and asked him and what do you think?

:-)

Cor
 
Hi Herfried,

?? > It's actually standard in <many systems> for the Enter key to move
?? > from field to field. (and has been for longer than you've been
alive!)
??
?? We are talking about development of applications using _Windows_ forms.

And in many companies the 'System' does the walking while Windows is
merely the pavement.

(Although I suppose maybe they should realise that Windows can also be a
travellator, which allows the system to merely stand upright and be carried
about.)

Regards,
Fergus

ps ?? Lol.
 
It is much faster for many people(mainly ones that use Financial
Applications) to use just the Number Pad than the full keyboard. Since there
are not many keyboards that sport a Tab key on the Num Pad, Users expect the
Software to adapt !!
 
Actually they're not... Why's that? Because you'd never find two that agree!
;o)

User Interfaces are designed as a unwritten standard of doing things. In the
last company I was in they went off in all sorts of tangents, basically
rewriting the event handling, key presses, etc for no apparent real reason
other than they wanted to do it differently. Different from the decided
Windows UI standard will tend to confuse, more than it would be found to be
practical.

It's like creating a COM object and deciding you don't really see the point
to AddRef and Release, so you just return zero. Yep, I've seen that done?!?!



Hi Cor,

The User is King!! **

Regards,
Fergus

** especially when it's me! ;-)
 
Hi Daniel,

~~ Different from the decided Windows UI standard will tend
~~ to confuse, more than it would be found to be practical.

Aye, 'tis often the way. But they pays the piper, so they chooses the
music. But most want you to tell them everything - including what they want -
you know, the mind-reading bit!

Skipping on AddRef and Release and returning zero? I see no problem. The
user switches off at the end of the day, so I just put 1GB RAM in my minimum
requirements spec. If they kick up a fuss about that, I arrange for my app to
have a GPF requiring a reboot - sometime around lunchtime.

Regards,
Fergus
 
What could be more "mind-reading" than assuming everyone has a Gig of ram?
;o)

Hi Daniel,

~~ Different from the decided Windows UI standard will tend
~~ to confuse, more than it would be found to be practical.

Aye, 'tis often the way. But they pays the piper, so they chooses the
music. But most want you to tell them everything - including what they
want -
you know, the mind-reading bit!

Skipping on AddRef and Release and returning zero? I see no problem. The
user switches off at the end of the day, so I just put 1GB RAM in my minimum
requirements spec. If they kick up a fuss about that, I arrange for my app
to
have a GPF requiring a reboot - sometime around lunchtime.

Regards,
Fergus
 
Hi Daniel,

No, no. It wouldn't do to assume that there'll be a Gig.
I demand and command!!. ;-))

Regards,
Fergus
 
OH WELL, that's completely different! ;-)

You sound more and more like Microsoft all the time, I think you're
infected... demanding stuff on us.

Hi Daniel,

No, no. It wouldn't do to assume that there'll be a Gig.
I demand and command!!. ;-))

Regards,
Fergus
 
* "Nice Chap said:
It is much faster for many people(mainly ones that use Financial
Applications) to use just the Number Pad than the full keyboard. Since there
are not many keyboards that sport a Tab key on the Num Pad, Users expect the
Software to adapt !!

Thanks. I only wanted to know reasons that make sense (like yours).
 
Hi Daniel,

ROFL. Something in the air, maybe. ;-))

Now if you'll just sign this EULA that gives me complete control to change
any of the wording in your posts as I see fit..... mmwaahaahaa [evil grin and
maniacal laughter]

Regards,
Fergus

This text is readright, copyright, leftandright and quite right.
This posting is provided "AS IS" with no warranties.
No liability will be accepted for anything.
Any and all words or meaning construed herein should not be
taken as representative of the beliefs or values of the author.
 
Hi Herfried,

Some are on a higher level yes.

But in OE is the Enter key as well to another row,

(Stupid me, you don't have OE)
Thanks. I only wanted to know reasons that make sense (like yours).

:-))

Cor
 
Back
Top