I am receiving 'the parameter is incorrect' on the oSS.nCleanup() line and the oSS.DropObject() line in the following script:: Set oScript = CreateObject ("ProvideX.Script") oScript.Init("C:\acct\Version45\MAS90\Home") Set oSS = oScript.NewObject("SY_Session") retVAL = oSS.nSetUser("bcs","bcs") retVAL = oSS.nSetCompany("ABC") retVAL = oSS.nSetDate("A/R","20140529") retVAL = oSS.nSetModule("A/R") retVAL = oSS.nSetProgram(oSS.nLookupTask("AR_AgedInvoiceReport_ui")) Set oARReport = oScript.NewObject("AR_AgedInvoiceReport_rpt", oSS) retval = oARReport.nSelectReportSetting("STANDARD") retval = oARReport.nSetKeyValue("ReportSetting$","STANDARD") retval = oARReport.nSetKeyValue("RowKey$","1") retval = oARReport.nSetKey() retval = oARReport.nInitReportEngine() retVal = oARReport.nProcessReport("PRINT") oSS.nCleanup() oSS.DropObject() Set oSS = Nothing Set oScript = Nothing If i comment out the two lines the script runs but leaves the task in process. Cannot figure out what is incorrect in the scripting.
↧