Creating opening screen of available forms

I want to emulate Sample Custom App Launcher but instead of launching/opening other apps, I want to display the forms the logged on user can access. My users are all assigned certain ROLEs (PI_NO) which give them specific tasks they can do based on that role. Such as, data entry, review and approve requests of those under them and probably more.

In the Sample Custom App Launcher, the Launcher table has the URL to each app listed. I would like to call a LINKTOVIEW(“FormBasedOnUsertable”)
Simply putting a specific LINKTOVIEW(“S_ASIA_Curate”) did not work. There is not a data type for Form or Expression that I could find.

I tried multiple other ways and nothing worked. Any ideas of how to have a menu type opening form, with or without images? Simply as a way to navigate the app based on data in the User table?

Lucinda

Hi lucinda, please use #control=S_ASIA_Curate in your spreadsheet and it should work with the App column.

Thank you Aleksi.


I have to click on the little red symbol next to #CONTROL=JFAPI_DATA_ENTRY
to open the form. We are close. What am I missing?

Open that main view’s definition and choose App link with the option “Row selected”.

1 Like

Thank you so much.

Hi @Lucinda_Mason
The Oil rig Inspection forms sample apps have lots of forms. You may find some ideas in those.

2 Likes

If I may trouble you again.

Previously I was using a form to have the user select their role (PI_NO) and then used an action to open the appropriate data entry form.

The action:
LINKTOFORM(
SWITCH( [PI_NO],
“2” , “JFAPI_Data_Entry”,
“3” , “JFCPI_Data_Entry”,
“4” , “JFPI_Data_Entry”,
“5” , “JFDPI_Data_Entry”,
“6” , “JFTPI_Data_Entry”,
“7” , “JFTPI_Data_Entry”,
“Enter Request” ),
“PI_NO”,[PI_NO])

That worked perfectly, but now I have a USERS table and want to get the PI_NO from it based on the USEREMAIL() of the logged in user.
The USERS table has USER_EMAIL and PI_NO as fields. How do I do the reference in the above expression to connect the logged in user and get the PI_NO?

Thanks again. I have a big learning curve, been out of doing any app/db design since my Microsoft Access days in the 80’s.

Lucinda

Thanks Lynn. I’ll definitely have to study those. So much to learn. Thanks for pointing me.

2 Likes

Instead of writing like [PI_NO], you could use LOOKUP(USEREMAIL(),“Users”,“Email”,“PI_NO”)

Thanks Alexsi. I’m not sure where to place the lookup expression.

This expression ran without errors but didn’t give me the results based on the user’s PI_NO.
LINKTOFORM(
SWITCH([PI_NO],
“2” , “JFAPI_Data_Entry”,
“3” , “JFCPI_Data_Entry”,
“4” , “JFPI_Data_Entry”,
“5” , “JFDPI_Data_Entry”,
“6” , “JFTPI_Data_Entry”,
“7” , “JFTPI_Data_Entry”,
“Enter Request” ),
[PI_NO],(LOOKUP(USEREMAIL(),“Users”,“User_Email”,“PI_NO”)))

Obviously Im not understanding. Or maybe I’m just calling the action from the wrong place. I was calling it from a dummy form based on the user table so that seemed to be capturing the record I was on instead of the logged in user.

The following two had errors in the way they were formatted.

LINKTOFORM((LOOKUP(USEREMAIL(),“Users”,“User_Email”,“PI_NO”)
SWITCH([PI_NO],
“2” , “JFAPI_Data_Entry”,
“3” , “JFCPI_Data_Entry”,
“4” , “JFPI_Data_Entry”,
“5” , “JFDPI_Data_Entry”,
“6” , “JFTPI_Data_Entry”,
“7” , “JFTPI_Data_Entry”,
“Enter Request” ),
“PI_NO”,[PI_NO]))


LINKTOFORM(
SWITCH((LOOKUP(USEREMAIL(),“Users”,“User_Email”,“PI_NO”),
“2” , “JFAPI_Data_Entry”,
“3” , “JFCPI_Data_Entry”,
“4” , “JFPI_Data_Entry”,
“5” , “JFDPI_Data_Entry”,
“6” , “JFTPI_Data_Entry”,
“7” , “JFTPI_Data_Entry”,
“Enter Request” ),
“PI_NO”,[PI_NO]))

Try…

LINKTOFORM(
SWITCH(LOOKUP(USEREMAIL(),“Users”,“User_Email”,“PI_NO”),
“2” , “JFAPI_Data_Entry”,
“3” , “JFCPI_Data_Entry”,
“4” , “JFPI_Data_Entry”,
“5” , “JFDPI_Data_Entry”,
“6” , “JFTPI_Data_Entry”,
“7” , “JFTPI_Data_Entry”,
“Enter Request” ),
“PI_NO”,LOOKUP(USEREMAIL(),“Users”,“User_Email”,“PI_NO”))

4 Likes

THANK you so much Aleksi. That worked. I so appreciate your help.

1 Like

You’re welcome