on 2024 Feb 13 10:12 AM
Hello!
I would like to use the drop down list as a way to run different scripts. So for example, when i choose "Timlønnet" i want to run a specific script, and a different script if i choose "Medarbejder i løntilskud".
I think i would need to create a script for the "onSelect" event on the dropdown list that uses an If/else or maybe else/if method, but i have not been able to find an example here in the SAP Community about how to do this.
Hope you can help, thank you!
Request clarification before answering.
You're on the right track, and yes, you can do this. Here are the steps for an example:
/* globals newKey */
var scriptNumber = newKey;
switch (scriptNumber) {
case "1":
session.utils.executeScript("wnd[0]/scrptPersonas_939100D454431EDEB2D9C6703D0C759A");
break;
case "2":
session.utils.executeScript("wnd[0]/scrptPersonas_939100D454431EDEB2D9C8E52B7BB59A");
break;
}
Of course, you need to paste your own script IDs at the appropriate places.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
62 | |
7 | |
6 | |
6 | |
6 | |
5 | |
4 | |
4 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.