I have an Advanced BAQ report written in Kinetic 2023. By “Advanced”, meaning I created a BAQ with parameters, created the RDD with the BAQ as the data source, set up the parameters in the RDD, then created the report style. I’ve added that report as a menu item and I’m able to run the menu item directly with no problems.
However, I’ve got a process where I’ve got a button in a standard entry form (DMR Processing) running in the classic interface. The idea is you press the button, it calls the menu item and passed the DMR number to the dialog box, and the user gets the report item up with the parameter already entered. This worked fine when the report was a standard BAQ report (created via the BAQ Report menu item). I used the launch form options in the calling program to pass the parameter to the menu item for the report, and the menu item pulled the parameter and filled it on the screen.
When I converted this from a standard BAQ report to an advanced BAQ report, the launching of the report via the menu item no longer works properly. (I want the advanced BAQ report because you can run that ALL-Company, that feature is not available with standard BAQ reports.) So, I have menu item UDDMRRPT which runs the report. When I run UDDMRRPT, it comes up with the parameter on the screen, the report style is set, etc. If I execute the following command from DMR Processing: ProcessCaller.LaunchForm(oTrans, “UDDMRRPT”, “UDDMRRPT”);
this doesn’t appear to even be running the same menu option. The parameter is not on the screen, the report style is blank, even the title bar on the window is different. Note that I’m not even trying to pass parameters at this point, just getting it to invoke the report.
So, anybody have any luck calling a menu item that runs an Advanced BAQ Report with parameters? Alternatively, I’m guessing that I can call the report directly from a button and pass the parameter, rather than calling a menu item which calls the report?
My Plan B for this is to mess with autoprinting, do something on the button that will invoke the autoprint where I can set the parameter in the data directive.
In this case the parameter value for “part” number is pulled from the myPart.Text box. The BAQ “getPartRev” is then run with the new parameter, and results are passed into a combobox of part revisions.
I hope this helps some! Good luck!
That’s a good snippet of code! That is code that would return the results of the BAQ into a dataset for use in the calling program (such as displaying in a grid). I’ve trying to invoke an SSRS report that’s based on a BAQ/Parameter.
it worked ,i was passing wrong values. Thank you.
but there is another issue. i want to print without preview button click
edvReportCriteria.CurrentDataRow.BeginEdit();
edvReportCriteria.CurrentDataRow[“QuoteNumber_2”] = int.Parse(values[0]);
edvReportCriteria.CurrentDataRow[“QuoteLine_1”] = int.Parse(values[1]);
edvReportCriteria.CurrentDataRow.EndEdit();
oTrans.SubmitToAgent(“SystemTaskAgent”, 0,0);
oTrans.SubmitToAgent(“SystemTaskAgent”, 0,0); is giving error invalid task agent.
Appreciate your help.