Page 1 of 1

Layouts do not remember last visited slide panel

PostPosted: Thu Feb 12, 2015 11:05 am
by ymeron
When navigating to Companies, the Contact Association panel is always shown, regardless of the last panel visited before moving away from Companies.
As far as I can tell, the problem is with script Company on Record Load, in the ElseIf statement that evaluates GetLayoutObjectAttribute ( $$sc_companyTargetPanel ; "IsFrontTabPanel" ). This seems to evaluate to True regardless of the actual panel shown. Possibly an FM bug, can't handle 3 deep nested panels?
Same problem with Invoices when the last visited panel is "Notes". When last visited panel is "PDF", works fine, so again leads me to suspect an FM bug in GetLayoutObjectAttribute when too many nested panels.
Can you come up with a workaround?
Thanks,

Yuval

Re: Layouts do not remember last visited slide panel

PostPosted: Fri Feb 13, 2015 11:26 am
by JasonYoung
Hi Yuval,

Thanks for the details! I'll take a look this Weekend!

Cheers!
-Jason

Re: Layouts do not remember last visited slide panel

PostPosted: Mon Feb 16, 2015 10:54 am
by JasonYoung
Hi Yuval,

This is "expected behavior" for GetLayoutObject attribute. However, I think I have a workaround with triggers, as the behavior you describe is what we want, and what it's doing now feels "buggy."

I should be able to test this today or tomorrow and will get back with you.

Thanks,
Jason

Re: Layouts do not remember last visited slide panel

PostPosted: Wed Feb 18, 2015 7:52 am
by ymeron
Thanks Jason!
Can you explain why this is the expected behavior for GetLayoutObjectAttribute?
Yuval

Re: Layouts do not remember last visited slide panel

PostPosted: Wed Feb 18, 2015 8:19 am
by JasonYoung
Hi Yuval,

Right, I was referring to "IsFrontTabPanel." It returns true if it's the front panel within it's control, regardless of whether it's actually visible or in focus, so these nested controls will return these false positives. Technically, it is the front panel, so it's not really a FileMaker bug, although it's always felt like one.

I think just referencing the note sub-panels as the last panel visited, rather than the parent main info and notes panel, but I need to test that.

Thanks!

Re: Layouts do not remember last visited slide panel

PostPosted: Sun Mar 15, 2015 10:40 am
by JasonYoung
Hi Yuval,

I finally had a chance to look at this and the easiest fix is to replace the Else IF line in the Record Load script triggers with just an IF. This forces the trigger to go to the last panel, regardless of what it "thinks" is the front panel.

Screen Shot 2015-03-15 at 12.35.54 PM.png
Screen Shot 2015-03-15 at 12.35.54 PM.png (149.6 KiB) Viewed 13429 times


Please make that change in all the On Record Load script triggers and you should be all set:

Screen Shot 2015-03-15 at 12.38.56 PM.png
Screen Shot 2015-03-15 at 12.38.56 PM.png (66.75 KiB) Viewed 13429 times


Cheers!
-Jason

Re: Layouts do not remember last visited slide panel

PostPosted: Mon Mar 16, 2015 2:42 pm
by ymeron
Thanks Jason!