avatar image
Former Member

setVariableValueExt Parameters using a universe

Hi,

I am using the following to pass the values of users into a prompt which is held in the universe. The prompt in the universe is called "Users" but the following doesn't seem to work. The source is a universe rather than BEx which I normally use. is there another format to pass the variable prompt name? I have searched SCN and found ps seems to be at the front of most of the variables? Is there a way I can find out the name I should use in the passing of the prompt name

DS1.setVariableValueExt("Users", users_names);

Thanks

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    Nov 04, 2016 at 06:51 AM

    Hi Leo,

    PS = passing 'prompt' value for 'single' case
    PM = passing 'prompt' value for 'multiple' cases

    Try below to test with HARDCODED values first, i.e

    *Make sure your Universe Prompt for Users is SET as optional

    For Single Value = DS_1.setVariableValueExt("psUsers", "John");

    For Multi Values = DS_1.setVariableValueExt("pmUsers", "John;Sam;Hector;Leo");

    Once this works for you, all you got to do is create a mechanism to feed setVariable script a String value instead of hard-coded "John".
    In Short, create a variable that will store all selected_string_values_for_Users, from Listbox or Multi-selection Drop-down component that user selects and you want to pass back to Universe.

    Hope this helps...

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 03, 2016 at 07:52 PM

    Hi Leo,

    You can pass the values by using DS1.setVariableValueExt().

    The values format needed to be in string format with each names separated by semicolon ";".

    In your case value for users_names = "user1;user2;user3;user4"

    Also, In universes "ps" is specified for single value prompt. The multiple value prompts will be prefixed "pm". It seems you are using single value prompt, so try passing only value. I think it will work.

    Thanks,

    Poovarasan

    Add comment
    10|10000 characters needed characters exceeded

Skip to Content