| | | | Browse by category |
Article ID: 851
Last updated: 05 Feb, 2008
Problem
The hasChanged() method never sets to TRUE if the user changes the text or numbers in some control other than a zEditLine. For example, if you have a zIntEdit and you change the value in it, the hasChanged will not switch to TRUE.
Cause
The cause was an oversight that needs to be fixed in the zApp code base.
Action
You need to override the ::command() of the zDialogFrame class.
The hasChanged() method never sets to TRUE if the user changes the text or numbers in some control other than a zEditLine. For example, if you have a zIntEdit and you change the value in it, the hasChanged will not switch to TRUE.
Cause
The cause was an oversight that needs to be fixed in the zApp code base.
Action
You need to override the ::command() of the zDialogFrame class.
In dialog.hpp in zapph, add the following to the :public section of the zDialogFrame class
virtual int command(zCommandEvt
*);
In the file dialog.cpp, near the bottom, add this method:
int zDialogFrame::command(zCommandEvt*ev) {
/** if YOU ARE using WIN16 use this if() statement */
if( ev-7gt;hiParam() == EN_CHANGE ){
/** if you are using WIN32 use this if() statement */
if( HIWORD(ev->parm1())
== EN_CHANGE ){
/** put the rest of this code below under your if statement */
zEditBase* wp;
wp=(zEditBase*)(zAppGetAppVar(app)->winMap()->get(
(HWND)(ev->parm2()) );
if( wp ) // To fix a problem
found with this fix.
wp->hasChanged(TRUE);
}
return 0;
}
This article was:
Helpful |
Not helpful
Report an issue
Article ID: 851
Last updated: 05 Feb, 2008
Revision: 1
Views: 2723
Posted: 02 Sep, 1997 by
Dean J.
Updated: 05 Feb, 2008 by
Dean J.
Others in this category
Powered by KBPublisher (Knowledge base software)