BusinessObjects Board

Displaying conditions

Hi all,

I have a report and I prompt the user from VBA and add those selected values as conditions in the report (not as sending the value back to the prompts in the query builder). Now I like to display those conditions in the report, Can anybody please tell me how to achieve that.

Thanks


broadcast (BOB member since 2004-11-18)

Create report variables to hold them, and at the same time that you are changing the data provider, save the choice into the report variable:

ThisDocument.DocumentVariables("Choice 1").Formula = FirstChoice

Now display the <Choice 1> variable on the report.


Dwayne Hoffpauir :us: (BOB member since 2002-09-19)

Dwayne,
I don’t have a fixed set of prompts from vba. I jump between different forms based on user input from the previous form. So I don’t know how many variables I may need. So I thought of traversing the Conditions in the report once I add all the conditions. But I am confused with the collection set of conditions as I am new to VB or SDK. The Report has only one dataprovider generating one query. Please help me how to parse through the conditions to capture the objects and values selected.


broadcast (BOB member since 2004-11-18)

Well, your code is already building / changing the data provider, so I’m a little confused on what more could be needed. That said, take a look at the code behind this utility. That utility copies a data provider, so it touches every part of the data provider, and should nudge you in the right direction.


Dwayne Hoffpauir :us: (BOB member since 2002-09-19)

my code is adding conditions to the query.It’s not building the whole SQL. I was trying to display the conditions as selection criteria in my reports… The link will help me I guess. Thanks


broadcast (BOB member since 2004-11-18)