Hi All,
I created a panel with few input fields and button.
My requirement is to filter data source using Input fields before loading the data source(Because of very large volume of data).
In Properties panel of Data Source, changed the DataBinding-->Load in Script to true.
Panel with Input fields:
I create the following script on the On click Button component(Apply Button).
PANEL_1.setVisible(false);
DS_1.setFilter("0SALESORG", INPUTFIELD_1.getValue());
DS_1.setFilter("0SALES_OFF", INPUTFIELD_2.getValue());
DS_1.setFilter("0SALES_GRP", INPUTFIELD_3.getValue());
DS_1.setFilter("0SALES_DIST", INPUTFIELD_4.getValue());
DS_1.setFilter("0CALDAY",{"low":DATEFIELD_1.getDate(),"high":DATEFIELD_2.getDate()});
DS_1.loadDataSource();
But when i execute the application i am getting the errors " Data Sourece DS_1 is not initialized"
Getting the error because, before loading data source, i am passing the values to the data source!
Is there a way to filter data source before loading into the application. ?
Note: Dont want to use prompts in the data source.
Data Source: Bex
Design Studio 1.6 SP2
Hi Kumar,
You MUST place the setFilter() calls immediately AFTER the loadDataSource() call. In this sequence, Design Studio knows to apply the filters BEFORE loading the result set. Otherwise you will receive the "not initialized error".
Regards,
Mustafa.
Add a comment