Skip to Content
0
Former Member
Apr 21, 2009 at 05:28 PM

DataProvider.runQuery not refreshing recordset?

34 Views

Hi All,

I have a requirement where from applicaiton A i need to connect to Application B (BO) and generate the report. I then need to take the html/or recorcds and display them in applicatgion A. I am trying to do the following

1) get the html using HTMLView. This seems to work but i cannot use the html as it as and will need to format it to work in applicaiton A.

2) get the dataprovidcer and recordset so i can build the target html based on the return results.. this does not seem to work.. no matter what u do the record set has thesame number of rows.. am i doing something wrong?this is what i am doing in the code

DocumentInstance doc = repEng.openDocument(292296);

DataProviders dps = doc.getDataProviders();

dps.getItem(0).runQuery();

Prompts prompts = doc.getPrompts();

int count = prompts.getCount();

String[] s = new String[]{"abcdef"};

prompts.getItem(0).enterValues(new String[]{"10"});

prompts.getItem(1).enterValues(new String[]{"SUP01"});

doc.setPrompts();

DataProvider lo1 = dps.getItem(0);

Recordset loSet = lo1.getResult(0);

System.out.println(" Dataprovider after refresh...FLOW COUNT.."lo1.getFlowCount()"-->"+loSet.getRowCount());

System.out.println(" Dataprovider after refresh....."dps.getItem(0).getName()"-->"+dps.getItem(0).getRowCount());

Any help is appreciated.. Thanks in Advance