Forum Discussion

ajackett's avatar
ajackett
New Contributor III
10 months ago

Retaining parameter value when navigating between forms - is it possible?

Hi all,

I am building some form templates for my workflow profiles, and have a query regarding the best way to setup the form template and entity parameter (setup below):

 

I would really like to be able to have users navigate between the forms, and the entity POV that they have selected in the parameter remain constant between forms. As it is now, when they move from a form, it always goes to the top entity in the list. I have some workflows with 20+ entities, and it may be that someone is working on the forms for just 1 entity at a point in time so has to re-select the entity each time. I've seen a "Sticky POV" idea raised on IdeaStream, but that hasn't moved since 2022. 

I have seen mentioned at Splash that there's an option to have the user state pov remain through a business rule, but haven't seen anything other than a SetUserState? And I'm not really sure how to write the code and apply it here. 

Any advice would be really helpful.  

  • kmd's avatar
    kmd
    Contributor

    Hi ajackett,

    Were you ever able to get this working?  I have the exact same request currently and I'm trying to figure out how to get this done.  If you were successful, I wonder if you would mind sharing with me how you accomplished this requirement.  Thanks very much

  • MarcusH's avatar
    MarcusH
    Contributor III

    'UserState' refers to a table in the application database (XFUserState) where the state information is stored. If you search for USERSTATE in the rules snippets you will get examples for the Get and Set. The information in UserState is available the next time the user logs in. If you just want the info stored for the session use Globals (globals.SetObject and globals.GetObject).

    GetUserState and SetUserState are used in an OpenPlace application (Data Import Schedule Manager - DSM). Look in the Dashboard Extender DSM_SolutionHelper for complete functions that use them.