Solved

Trigger script upon opening a request

  • 23 November 2021
  • 4 replies
  • 59 views

Userlevel 1
Badge +2

Using the FSM web client, I’ve currently not found any way to trigger a script when the request is loaded. (After clicking on it when searching for a request).

 

We have different tabs which we need to be hidden/shown if the request contains specific information, previously we’ve done this using the “Custom Code” on the field which has the Initial focus set, but this is not possible to use on the web client.

 

 

 

 

icon

Best answer by Saranga Amaraweera 24 November 2021, 10:50

View original

4 replies

Userlevel 5
Badge +9

Hi @Bjorn ,

 

You can use the AfterDataLoad event as a screen event for the request screen. Navigate to the request screen from UI designer. 

 

Click the View screen events icon from tool bar

You can assign the required custom client script for the screen AfterDataLoad of the results. 

 

Screen Events


Hope this answer helps.

Best Regards,
Atheeq​​​​​​​

Userlevel 1
Badge +2

I have tried to do it this way, but the script is triggered when the search screen is opened, and not when the specific request is loaded;
 

 

It seems that this event is still loaded on the search screen and not specifically when the request is opened, and is applied to all requests opened from the screen.

Tested with setting up an alert, and this only triggers when the search screen is opened/search is perfomed, and twice when going back from a request screen to the search.

On FSM6 U13.

 

 

Userlevel 5
Badge +15

Hi @Bjorn ,

Have you tested the same script with AddEditOpened event?  This occurs after the AddEdit section has opened in which only occurs once.

Userlevel 1
Badge +2

I hadn’t tried that, seems like that worked! Thanks :)

 

Reply