Hi,
I haven't worked on Text Fields before. Now I am
forced to include them in my PDA application.
I have 3 different text fields on my form . But
somehow I am not able to get focus on the text fields
when I select them . I went thro' the manual and few
sample examples .But I didn't succeed. If I write the
following code in my FormOpen Event ,it will set focus
to one field which I mention in my code and If I try
to set focus to other fields by selecting them,it
doesn't work.
case frmOpenEvent:
frm = FrmGetActiveForm();
FrmDrawForm( frm );
fldIndex =
FrmGetObjectIndex(frm,ChangePWUnnamed2006Field );
FrmSetFocus(frm, fldIndex);
//This sets focus on to the field mentioned above.
case keyDownEvent:
if(event->eType = fldEnterEvent)
{
switch(event->data.fldEnter.fieldID)
{
case ChangePWUnnamed2005Field:
frm = FrmGetActiveForm();
fldIndex =
FrmGetObjectIndex(frm,ChangePWUnnamed2005Field );
FrmSetFocus(frm, fldIndex);
// str= FldGetTextPtr(fld); //FldHandleEvent();
//fld = GetObjectPtr(ChangePWUnnamed2005Field);
// FldGrabFocus(fld);
handled = true;
break;
case ChangePWUnnamed2006Field:
frm = FrmGetActiveForm();
FrmDrawForm( frm );
//FldHandleEvent();
fldIndex =
FrmGetObjectIndex(frm,ChangePWUnnamed2006Field );
FrmSetFocus(frm, fldIndex);
handled = true;
break;
}
}
break;
//This code doesn't work.
AM i doing something wrong here???
Thanks in advance.
Amritha.
=====
Necessity is the corner stone of all newer discoveries and inventions.
____________________________________________________________
Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/