![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I'm a novice using FMP 9 Adv. I have a layout that shows a portal of students with some related fields. Is there way to make the field "Graduated" to Hide or Show by a click of a button? |
#3
| |||
| |||
|
|
senriz wrote: I'm a novice using FMP 9 Adv. *I have a layout that shows a portal of students with some related fields. *Is there way to make the field "Graduated" to Hide or Show by a click of a button? There are a few approaches. One is to create a global in the child table, and have the script toggle the global value 1/0 create a tunneled rel by adding an additional TOC: A::B::B_switched where A is table A the parent TOC , your layout B is the child rel showing your portal B_switched is the toggled filtered TOC A::B is your existing rel and portal so the rel B to B_switched *is b_id::b_id *plus g_swicth::c1 ( a calc value 1) *; so a multiparameter rel replace the b_field in the portal to toggle *with b_switched_field alternatively you could create a calc field in B, that returned the same result as the target field to toggle, conditionally on the toggle value, and add that field to the portal; this would not allow editing the field though. |
#4
| |||
| |||
|
|
On Nov 11, 2:38*pm, 105 <corti... (AT) internode (DOT) on.net> wrote: senriz wrote: I'm a novice using FMP 9 Adv. *I have a layout that shows a portal of students with some related fields. *Is there way to make the field "Graduated" to Hide or Show by a click of a button? There are a few approaches. One is to create a global in the child table, and have the script toggle the global value 1/0 create a tunneled rel by adding an additional TOC: A::B::B_switched where A is table A the parent TOC , your layout B is the child rel showing your portal B_switched is the toggled filtered TOC A::B is your existing rel and portal so the rel B to B_switched *is b_id::b_id *plus g_swicth::c1 ( a calc value 1) *; so a multiparameter rel replace the b_field in the portal to toggle *with b_switched_field alternatively you could create a calc field in B, that returned the same result as the target field to toggle, conditionally on the toggle value, and add that field to the portal; this would not allow editing the field though. Thank you. I'll give this a try. |
#5
| |||
| |||
|
|
In article cd997f50-4e03-4cb4-9a07-bf070561a... (AT) w37g2000prg (DOT) googlegroups.com>, *senriz <dbsen... (AT) gmail (DOT) com> wrote: On Nov 11, 2:38*pm, 105 <corti... (AT) internode (DOT) on.net> wrote: senriz wrote: I'm a novice using FMP 9 Adv. *I have a layout that shows a portal of students with some related fields. *Is there way to make the field "Graduated" to Hide or Show by a click of a button? There are a few approaches. One is to create a global in the child table, and have the script toggle the global value 1/0 create a tunneled rel by adding an additional TOC: A::B::B_switched where A is table A the parent TOC , your layout B is the child rel showing your portal B_switched is the toggled filtered TOC A::B is your existing rel and portal so the rel B to B_switched *is b_id::b_id *plus g_swicth::c1 ( a calc value 1) *; so a multiparameter rel replace the b_field in the portal to toggle *with b_switched_field alternatively you could create a calc field in B, that returned the same result as the target field to toggle, conditionally on the toggle value, and add that field to the portal; this would not allow editing the field though. Thank you. I'll give this a try. Another approach is to put a tab control in the layout. Put the portal that shows the field "Graduated" on one of the tab controls, and a portal that does not show that field on the other tab control. But this raises a question: Do you want to limit which users can toggle between the two? If so you ned to use a calculation or script and limit access by privilege set. |
![]() |
| Thread Tools | |
| Display Modes | |
| |