Skip to Content

The Design Studio Scripting language is very similar to Java Script. It can be executed both on the Browser as well as the Server.

The scripts follow a “Push” model where in it pushes data to the Components.

This is different to BEx Components and XCelsius where the Components “Pull” data from data sources.

Such kind of script using “Push” model is easy to understand in more complex scenarios.

There are different data types like Integer, String, Boolean.

We also have BI Specific types like Dimension, Member, Filter, ChartType and so on.

All Methods are invoked with dot ” . “

You can enter Control + Space for help after the dot. So all the methods that are available will be displayed and you can select one of them.

Each line of the script should end with a semi colon ;

Let us see an example of a small application where we will try to use some scripting concepts.

I have build a small application as below. I selected a Tab Strip component. And I have placed a Cross tab and a chart in each tabs.

I have two BEx Queries which I have used as a datasources for these.

Image1.jpg

This is how the application looks like when we execute it locally.

Image2.jpg

Now lets add a Dimension Filter in the Tab 1. You can see in the image below how easy it is to align all these components in Design Studio.

It shows you the exact distance of any component from the top, bottom, right and left. If you have worked on WAD before you would know how difficult it is

over there to align the components in a page.

Image3.jpg

Check the properties for the Dimension Filter. Click on Dimension. This will open a window where you can select a dimension to bind it with the filter.

Image 4.jpgImage5.jpg

As shown below now the Dimension Filter Component is binded to Distribution Channel.

Image6.jpg

Now Drag a List Box from the left to your application.

Image7.jpg

When you check the properties of Application App_Demo you will see an event “Startup”. Click on this event and it will open the script editor.

We need to provide values to the list box which will be displayed when the application runs.

Image8.jpgImage9.jpg

As shown above after the dot when you press Control + Space the help will open and show you list of different methods that are available.

Image10.jpg

We have selected the method Set Items. As shown above when you select any method the help will also show you the detailed description of what does the method do. We need to get the list of members which we want to populate in the list box.

Image11.jpg

Now we have selected the getMemberList method and there are four parameters inside the method which we will have to set.

We are going to select the KeyFigures here. Member presentation will be set to External Key and member display will be text and maxmember is 10.

Image12.jpg

Now open the event On Select of Component LISTBOX_1 and write below mentioned script.

Here we are getting the selected value of listbox and applying it as a filter to DS_1 and DS_2.

Image13.jpg

Now run the application and you will see a filter on Distribution Channel as below. Click on that to select a value for Distribution Channel.

Image14.jpg

Image15.jpg

Image16.jpg

Image17.jpg

As shown above you have a List Box available for the three key figures Order Volume, Order Quantity and Open Orders.

When you select any one of these, the chart and the cross tab automatically show values related to it.

So as you have seen above scripting in Design Studio is very easy to use and you have lot of help available.

You have different events which provide you capabilities like select a row of the report and jump to a detailed report, jump to a URL and so on.

You can also set different components as either Visible or invisible by using specific events.

To report this post you need to login first.

9 Comments

You must be Logged on to comment or reply to a post.

  1. Preeti Tripathy

    Hi,

    When I added the list box and and the dimension filter in the first tab, the data source is getting filtered based on first value in listbox only.When other values are selected in list-box

    the data source is not filtered,instead the filter is reset to all values.

    Please help.

    Regards,

    Preeti

    (0) 
  2. VaraPrasadraju Potturi

    Hi Mansi,

    Thanks for the blog.

    We have a similar requirement to use both Dimension filter and List box. List box values has to updated based on cross tab char which will be filtered using Dimension filter. But this is not working.

    I posted a message on the same issue with details. Could you please help to resolve this issue.

    Thanks,

    Raju

    (0) 
  3. Vaibhav Singh Rathore

    THANKS FOR THE USEFUL INFORMATION, but i have one question , if we use listbox and dropdown both how we can differentiate it at the event script, because when i am selecting any field from both of them it shows me incorrect data, else it works fine on individual basis.

    Need your suggestions please.

    Thanks for the post

    Regards

    Vaibhav

    (0) 
    1. Eshwar Prasanna

      Whether you are selecting an event for the dropdown or the listbox is entirely dependent on the alias you assign before the “.” to invoke the methods.

      If your dropdown is named “DROPDOWN_1”, then using DROPDOWN_1.<method> would only refer to the dropdown.

      Thanks and Regards,

      Eshwar Prasanna

      (0) 
  4. Las W

    Hi Mansi,

    Very well illustrated. When clicked on images, it looks really small if this can be improved on your next blog would be appreciated. Good job!

    Thank you.

    Regards,

    Las.

    (0) 

Leave a Reply