Re: Validation and Undo

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



"John Richardson" <j3richarson@xxxxxxxxx> a écrit dans le message de news:
%235aRukaAGHA.2644@xxxxxxxxxxxxxxxxxxxxxxx

| But, as the user edits a field, the control itself offers a Validation
| event, which is hinting at a Transaction at the control level. So, a
Field
| transaction should be viewed as beginning when the control is focused,
| ending when the control is unfocused, and I would think that a cancel
should
| be implemented by ESC, or some other commonly understood method.
|
| For some reason, I figured this was a default behaviour of the Control
| object, but it is not. In my view, this behaviour is fairly natural
| assumption... it makes more sense than say the SHIFT-SPACE behaviour on
the
| datagrid, that is for sure.

FMPOV, the Validating event in the Control class fits very well into the
Model View Presenter framework as it is a response to a user interaction
trying to quit editing a value.

The edit is a means of entering data that will be passed to the underlhying
data member. The Validating event gives the program an opportunity to
interrupt the flow of data to the data member and prompt the edit to refresh
itself to the, as yet unchanged, underlying data member.

Joanna

--
Joanna Carter [TeamB]
Consultant Software Engineer


.



Relevant Pages

  • Re: I want to get rid of a beep
    ... If I press enter when the edit box has focus, ... MyEditBox::MyEditBox(CWnd *parent, UINT nID) ... You cannot possibly know the dimensions of an edit control so ... MyEditBox::OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags) ...
    (microsoft.public.vc.mfc)
  • Re: how to stop last edit date changing when record just viewed or copied
    ... (All this applies to subform just the same as main forms.) ... ruling out Dirty or BeforeUpdate??). ... of the user and then sets the visible property of Edit, Delete, Add, ... its contents to another control. ...
    (microsoft.public.access.formscoding)
  • Re: programmatically initialize properties of dialog controls
    ... for font I couldn't manage without specifying font name. ... concatenating in edit box - it just occurred to me that all the same I ... >>First make sure that you have attached a variable to any control that you ... > or check boxes, you can create value variables which you initialize before ...
    (microsoft.public.vc.mfc)
  • Re: Dynamic ImageButton Handler
    ... "how do you associate the button with the edit ... do the same for your edit control. ... You could then find the controls when you retrieve your CommandArgument ... Dim btn As Button = TryCast ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Form Doesnt Go To New Record
    ... > navigation buttons provided by having the form's NavigationButtons ... Edit the data in a control. ... SetDefaultValuesand False calls the Public Sub RemoveDefaultValues(). ...
    (microsoft.public.access.gettingstarted)