June 3, 200619 yr I have a script that adds new records. The layout that is used to enter the new record is different for different users (one type of physician uses one form and another type of physician uses a different form). Within the "add new record" script step, I want to determine who the user is and then send them to the appropriate form. I tried the following script step: Go To Layout [Case (Get (AccountName); "admin"; LayoutNames ("EP INVOICE"); Get (AccountName); "cohen"; LayoutNames ("CATH INVOICE"))] where admin and cohen are two different users and EP INVOICE and CATH INVOICE are the desired destination layouts. I get no error messages from this calculation, however, the script seems to get stuck at this step. I also tried a If/ElseIf statement which also didn't seem to work. Any thoughts would be appreciated. Thanks. Rick (newbie)
June 3, 200619 yr Try this: Case ( Get (AccountName) = "admin"; "EP INVOICE"; Get (AccountName) = "cohen"; "CATH INVOICE"; "") I think your formatting of the case statement is the problem Hope that helps :
Create an account or sign in to comment