cancel
Showing results for 
Search instead for 
Did you mean: 

Radio buttons and drop-down

Former Member
0 Kudos

Hi, once again!

I wanted to know is there any reasonable quality tutorial or written steps for radio buttons and drop-down menus? Because this - SAP Screen Personas 3.0: Radio Button Scripting Demo - YouTube is unreadable and in-watchable

Accepted Solutions (1)

Accepted Solutions (1)

Carifaine
Active Participant
0 Kudos

Hi Diana,

you may find this helpful: Scripting: onSelect - Use Dropdown Listboxes to streamline text input - SAP Imagineering - SCN Wiki

There is no tutorial for radio buttons as far as i know. Do you have any specific questions we may help you with?

Former Member
0 Kudos

Thanks Christoph! This is a quite acceptable guide for drop down. Basically I would like to find some general walk-through on how to get out most of the radio buttons/ drop downs or check boxes using them in conjunction with Screen Personas, I mean, something like usual practice and how to configure them correctly, so to say.

Thanks,

Diana

Former Member
0 Kudos

Christoph,

Now we have a specific case I would like to get help with - we want to make a dropdown list containing from various transactions regarding G/L account master data, so when specific label is selected, user is taken to the appropriate screen, e.g. FSP0. Dropdown looks like this:

How would I achieve that?

Thanks!

Carifaine
Active Participant
0 Kudos

Hi Diana,

if you have your dropdown configured like this:

it should be a simple script like this:

var transaction = session.findById("wnd[0]/usr/cmbPersonas_1453131673643").key;          //this is the reference to your dropdown

switch (transaction) {

  case "1":

  session.callTransaction("MM01"); break;

  case "2":

  session.callTransaction("MM02"); break;

  case "3":

  session.callTransaction("MM03"); break;

  default:

  session.utils.log("No transaction chosen");

}

Didn't evaluate it by now due to system maintenance but it should work like this.

@Edit: Did a short check, works fine for me. Just enter your transaction codes and the reference to your dropdown box.

Regards,

Christoph

tamas_hoznek
Product and Topic Expert
Product and Topic Expert
0 Kudos

Steve's response in this thread tells you exactly how to do this.

Former Member
0 Kudos

Thanks! I tried it that way - work when validating and executing script, but when assigned to onSelect - nothing happens. Tried also with session.startTransaction(string tcode); - still nothing happens. But then (after selecting an dropdown option which doesn't work) flavor becomes uneditable - it showing error. and when I press anywhere else it takes me to the last transaction chosen from dropdown. where is the mistake?

Please see the screenshots below.

Dropdown:

Scripting, when validating is successful, bet when choosing some value - in logs the default option - "no transaction chosen"

but if executing from scripting - it takes to the relevant transaction

but out of scripting - the choices doesn't work - no matter which drop-down option I choose it stays in initial screen, but when I try to edit or check script again - it goes to the transaction and shows error.

Former Member
0 Kudos

Thanks, I tried both variants - there are still misbehaviour. Please see answer to Christoph.

Carifaine
Active Participant
0 Kudos

Please make sure that you get the right values into variable "transaction". I'd suggest to debug it or add some log entries to have a clear view on what actually happens while executing the script. Do you have any additional actions in the script or is it only the switch-case-structure?

I didn't experience such an error by now, hope anyone from the screen personas team might help here...

Former Member
0 Kudos

Hi,

I have only this switch-case structure in script.

Below I've attached the full script. When I chose the option that should go to the transaction (e.g. case with the value "1" in drop-down configuration), there are the default values logged into console. I have changed the script from beginning - same result...

0 Kudos

for your Dropdown, put tcodes in value field.

Then all you need in the script is this line:

session.callTransaction(newKey);

no need for switch case..


then attach this script as onSelect event for your dropdown.

What is newKey?

Please read Tamas's link below where Steve explains

OR

launch Script documentation in your system:

http...../sap/bc/personas3/core/resources/doc/PersonasScriptingAPIDoc.html

lastly, please learn how debugging works in scripting:

Debugging options in SAP Screen Personas 3.0 - SAP Imagineering - SCN Wiki

Regards,

Sushant

0 Kudos

hi diana,

may be your system needs some updates. Check note 2222773 please and update your kernel patch and client note accordingly.

Sushant

Former Member
0 Kudos

Thanks Sushant. I am on 3.0 SP01. and the client note is updated.

And I have configured the drop-down control like you:

Edit G/L account chart of accts data - FSP0

Copy G/ account MD: send - FS15

and put the line in script, but it doesn't work. I don't understand what I'm doing wrong, why it doesn't work, when according label with key is selected?

my script line is like Steve has mentioned in his answer and as mentioned here with source.key

session.callTransaction(source.key);

It work on execution while in scripting mode,but after then doesn't when selected from drop-down.

0 Kudos

so if you are saying that onSelect for your dropdown is not working then check your kernel patch level.

I tested with 317/318, it works!!

Sushant

Former Member
0 Kudos

We have kernel patch level 312, but health check tool shows the green light? Can it still be the trouble-maker?

0 Kudos

hi diana,

sorry i dont have any 312 system where i can check whether onSelect for a dropdown is triggered or not.

But i did on 317/318 and it works there. Based on the info you have provided till now, your scipt is not called at all when you select an entry from dropdown.

So best thing i would say is that to upgrade kernel patch level.

Sushant

Answers (1)

Answers (1)

0 Kudos

Hi Diana,

As part of Powerplay series (http://videos.personas.help), we are in process of releasing good quality videos.

If you have any special request, please let us know.

Meanwhile, what specific question regarding radio button / drop down?

Regards,

Sushant

Former Member
0 Kudos

Thank you, this is really good to hear that you are making those videos, because Screen Personas really is missing good guide-through and examples how to use offered functionality by Screen Personas. So for this - thumbs up   fo example I cannot find good explanation on HTML viewer in screen personas 3.0. - can I format it somehow, to shows some specific place in the homepage? Or adding a widgets to a screen, e.g. accountants frequently ask for calendar. As I'm a newbie to Screen Personas, I often feel that those explanations on SAP marketplace is not meant for me


Thanks,

Sincerely,

Diana

Carifaine
Active Participant
0 Kudos

Hi Diana,

did you have a look at this course?

https://open.sap.com/courses/sps1

It explains a lot of the standard functionality and how you can address certain controls. Maybe it helps you to get an idea of how to work with most of the controls. Still the videos for specific topics will be more useful

Former Member
0 Kudos

Christoph, yes I have familiarize myself with the course, these are the essential basics only. What i'm trying to say here is that this tool is missing some kind of a portfolio from creators, showing all possibilities within screen personas with a proper step-by-step guide, e.g. is it possible to add shortcut to a external document on user's computer, or to add downloadable pdf, etc...

Now I have to use very much time trying to find information I'm interested in or ask here and then wait for the answers, instead, it would be nicer if there was something like a complete manual or portfolio, explaining how exactly function should be used and what could be achieved with that.

Anyhow, many sincere thanks for your input

0 Kudos

Hi Diana,

we do have lot of resources out there which do covers most of the things.

Of course, there can be certain scenario based requirements which you want and are not there. We are building those based on the feedback and topics which we commonly receive form customers. A great place for you to join the personas community and see what other customers are doing is by joining our monthly practitioner forum meetings

Regards,

Sushant