This code always worked for me (in both of your scenarios):

fldIndex = FrmGetObjectIndex(frm, MyField);
FrmSetFocus(frm, fldIndex);

Bozidar


> -----Original Message-----
> From: Fawcett, Mitch [mailto:[EMAIL PROTECTED]]
> Sent: Monday, May 03, 1999 9:56 PM
> To: 'PalmDevForum'
> Subject: Returning focus to a field
>
>
> Has anyone encountered anomalous behavior when returning to a
> form as in the
> following:
>
> Scenario #1)
> FormA is opened and a table item is selected.
> FormA calls FrmPopupForm (FormB).
> FormB calls a FrmReturnToForm (FormA) and tries to put the focus and an
> insertion point in a field on FormA.  However the insertion point does not
> appear in the field. There is no complaint from Palm.
>
> Scenario #2)
> The exact same scenario as above except FormA starts off without a table
> item being selected.
> In this case there is no problem with FormB returning to FormA and having
> the insertion point show up in the field on FormA.
>
> I don't expect a whole lot of thinking on this one, just has anyone seen
> anything like this happen before I go into a major code hunt.
>
> Thanks.
>
>

Reply via email to