Code: Select all
Sub ContractorWONOTDONE
Dim pProp(1) As New com.sun.star.beans.PropertyValue
sURL = ConvertToURL("C:\Users\Public\databases\mydb\mydb.file.odb")
oDoc = starDesktop.loadComponentFromURL(sURL,"_blank",0,Array())
oReps = oDoc.getReportDocuments()
oAConnection = oDoc.DataSource.getConnection("","")
'set properties
pProp(0).Name = "ActiveConnection"
pProp(0).Value = oAConnection
pProp(1).Name = "OpenMode"
pProp(1).Value = "open" 'OR: openDesign
'load the form: TargetFrameName and SearchFlags aren't used
oReport = oReps.loadComponentFromURL("Work Orders- Contractor-Not Done","_blank",0,pProp())
End Sub
Basic runtime error
An exception occurred
Type: com.sun.star.task.ErrorCodeIOException
Message:.
And from that point on things go loopy. I cannot open any report, even within the db, forms will not open in the db. When i close out of OOo and open it up again, everything will work except the report macros. The only way to get those to work again is to restart the computer. After that everything works beautifully again, that is, until I have to make a change to a report. I am running OOo as a front end client-server set up connected through JDBC (am I specifying that correctly?). Even though I have a work around, I would rather not have to restart the computer every time I make a change to report function of the db. Any suggestions out there?
Thanks
TJM05