I have requirement for report i.e when user select multiple sales order form the sales list page and when he run the report then it should run for all the selected sales orders
I tried this code but didnt work for me
public class TSCPerformaInvoiceController extends SrsReportRunController
{
public static TSCPerformaInvoiceController construct()
{
return new TSCPerformaInvoiceController();
}
protected void prePromptModifyContract()
{
SalesTable salesTable;
FormDataSource fds;
List salesIdList = new List(Types::String);
TSCPerformaInvoiceContract contract = new TSCPerformaInvoiceContract();
contract = this.parmReportContract().parmRdpContract() as TSCPerformaInvoiceContract;
fds = FormDataUtil::getFormDataSource(this.parmArgs().record());
if(this.parmArgs() && this.parmArgs().dataset() == tableNum(salesTable))
{
for(salesTable = getFirstSelection(fds) ; salesTable ; salesTable = fds.getNext())
{
salesIdList.addEnd(salesTable.SalesId);
}
if(contract)
{
contract.parmSalesId(salesIdList);
}
}
}
public static void main(Args _args)
{
TSCPerformaInvoiceController controller = TSCPerformaInvoiceController::construct();
controller.parmArgs(_args);
controller.parmReportName(ssrsReportStr(TSCPerformaInvoiceReport, TSCReport));
controller.startOperation();
}
}
i create contract class and taking the parameter in list
