Created a SSRS report for a label, need to be able to print it from a dashboard

Hello,

I am trying to find the best way to print inventory labels on a zebra label printer.

I created a BAQ with the information needed. I created a report in BAQ Report Designer and have it working so I can print the labels to a zebra printer. Works fine.

Now I just need to have a dashboard where they select the labels they want to print by changing a field on the dashboard to be the number of that label they want.

After they fill that out, I will set up a button to click that would start the printing.

I am unsure on how to get the dashboard to send the information to the BAQ Designed label I created.

Is it possible? Or should I rethink it and create a label in bartender?

Any help is appreciated.

on the baq report you will need to create filters and use the dashbaord to send the data to the filters.

I am not sure on how to do that.

Could you provide information or point me in the direction I need to go to pass the data from a dashboard to a BAQ Report?

I would think it would need the PartNum.
I would also need it to print the number of copies of that label that was selected in the dashboard.
The field in the dashboard is just a calculated field right now that returns 0. I made it updateable so the number could be changed in the dashboard.
Would the dashboard send the same label X times or is there a way to send the data to the BAQ report and have it print the required number of labels there?

Thank you for the quick reply. I appreciate it!

I think i have an snippet hold on

this could help

private void PrepPrintJob(BAQReportDataSet ds, string reportID, string baqid, Session session, bool UseDefaults, bool Print, string PackNum, string TRD)
    {
        // Provide print dialog support
        PrintDialog printDialog = new PrintDialog();
        ds = bop.GetNewBAQReportParam(reportID);
        DynamicReportAdapter dra = new DynamicReportAdapter(oTrans);
        dra.BOConnect();
        dra.GetByID(reportID);
        bop.GetDefaults(ds);


        if (!UseDefaults)
            if (printDialog.ShowDialog() != DialogResult.OK)
                throw new Exception("Printing canceled");

        // Params that need setting
        
        ds.BAQReportParam[0].Option01 = PackNum;
        ds.BAQReportParam[0].Option02 = TRD;
        ds.BAQReportParam[0].AutoAction = "SSRSPREVIEW";
        ds.BAQReportParam[0].AgentID = "SystemTaskAgent";
        ds.BAQReportParam[0].DateFormat = "m/d/yyyy";
        ds.BAQReportParam[0].NumericFormat = ",.";
        ds.BAQReportParam[0].ReportID = reportID;
        ds.BAQReportParam[0].BAQRptID = reportID;
        ds.BAQReportParam[0].BAQID = baqid;
        ds.BAQReportParam[0].ReportStyleNum = 1;
        ds.BAQReportParam[0].Summary = false;
        ds.BAQReportParam[0].Filter1 = dra.DynamicReportData.GetXml();
        // Print Params
        if (Print)
        {
            //  Don't need this to preview.
            ds.BAQReportParam[0].PrinterName = printDialog.PrinterSettings.PrinterName;
            ds.BAQReportParam[0].RptPageSettings = Ice.Lib.Report.EpiPageAndPrinterSettings.CreatePageSettingsAsString(printDialog.PrinterSettings.DefaultPageSettings);
            ds.BAQReportParam[0].RptPrinterSettings = Ice.Lib.Report.EpiPageAndPrinterSettings.CreatePrinterSettingsAsString(printDialog.PrinterSettings);
        }



        ds.BAQReportParam[0].WorkstationID = Ice.Lib.Report.EpiReportFunctions.GetWorkStationID(session);
        ds.BAQReportParam[0].ReportCultureCode = Ice.Lib.Report.EpiReportFunctions.GetRptCultureCode(session);
        ds.BAQReportParam[0].ReportCurrencyCode = Ice.Lib.Report.EpiReportFunctions.GetRptCurrencyCode(ds.Tables[0].Rows[0]["ReportCultureCode"].ToString(), session);
        ds.BAQReportParam[0].SSRSRenderFormat = "PDF";
        bop.SubmitToAgent(ds, "SystemTaskAgent", 0, 0, "Ice.UI.Rpt.BAQReport;" + reportID);


    }
3 Likes

Hey,

That doesn’t help me much without some context.

Where would your code go?

How is it triggered?

Where does it pull the argument data to send to your method PrepPrintJob?

Where does the number of copies per label get controlled?

Any help is appreciated.

this is an example code i did for something else now you need to adjust the code to serve your needs for your request i dont have a code that is custom made for your problematic.

the code is trigger with a button
the arguments for PrepPrintJob you need to pull it from your dashboard

1 Like

Shawn,

did you ever find a solution for this? Also, if you still have the BAQ could you post it please? I am trying to make a similar thing but no idea where to start.