If you email a solution to someone directly, how does it help anyone else here?
Can’t post replies with code
Okay i give up. My forum post with code on them won’t show up. I’m pasting it here to see if it shows up.
I’m using the trial in a C# Windows Application. I can connect to the QB database. I am attempting to return data from a report i normally run in OpenSync. Its the Profit and Loss Budget Overview Report. Here is the code i used which i had to figure our on my own using some samples from this forum and trying to figure it out on my own.
CoreObjX80.QBConnection QBc = new CoreObjX80.QBConnection();
QBc.Connect("", "My App Name", CoreObjX80.qbEnumFileOpenMode.qbOpenModeDontCare, "9999999999", "C:\\QBDB\\MyQB.QBW");
CoreObjX80.Report rep = new CoreObjX80.Report();
rep.BaseReport = CoreObjX80.qbEnumReports.qbRptProfitAndLossBudgetOverview;
rep.DateMacro = CoreObjX80.qbEnumReportDateMacro.DateMacroCustom;
rep.STartDate = Convert.ToDateTime("1/1/2018");
rep.EndDate = Convert.ToDateTime("12/31/2018");
rep.SummarizeColumnsBy = CoreObjX80.qbEnumReportColSortFields.qbRptColSortday;
rep.SummarizeRowsBy = CoreObjX80.qbEnumReportColSortFields.qbRptColSortAccount;
rep.ReturnColumns = CoreObjX80.qbEnumReportReturnRowCol.qbReportReturnAll;
rep.ReturnRows = CoreObjX80.qbEnumReportReturnRowCol.qbReportReturnAll;
string myXML = rep.SaveToXml() ;
It returns the following XML
Its not returning any data. Are there any decent C# examples on how to return the data using this product?
Now this one worked – Hmmmm
It definitely something to do with the newest version. I uninstalled OpenSync and reinstalled. If i use 3.0.19 the selections show the correct properties. If i choose the upgrade option to 3.0.24 then the selections are incorrect.
Very strange. I open the application for the first time and select a task. The properties to the right shows the correct data. If i select on another one, the properties of the first task are displayed. I’m afraid to run or edit anything because i don’t know what it will do. See attached screen shots.
Can you help?
There appears to be more problems than that. The details section is listing the wrong output table as well. All of my Tasks were imported from the version 2 configuration so maybe the import process is at fault. I’m not sure.
Do you have another product that would allow me to run multiple reports? Like COREOBJX through Visual Studio or something like that?
Sorry for the delay. It is attached. I’m getting ready to run the reports again tomorrow.
I closed QB and it does the same thing.
A solution for this is looking like it is going to get a bit complicated so I wanted to make sure i was clear on the problem i was having. I don’t need to really look up when an account assigned to an item was changed and by who or anything like that. I just need to run a SQL query and have the results match what i see in a report in QB. If i run a report for 2015 in QB it will accurately show the amounts and somehow know that an account was assigned to an item differently in 2015. When i run a report for 2016 or at any time after the account was reassigned to a different account, QB also knows that and displays the proper amounts and account information in the details. I assumed this historical entries would be stored in the transaction table but it doesn’t seem to be the case. I just thought i needed to link to another table to match up the right item and account. Shouldn’t the transaction table hold all the historical data?
Boy i wish I would have known that earlier. I have lots of hours wrapped up in this project. But Ok. I had to dump reports for the budget data so why not this. Any idea what report i would think about running to get the change history of at least the items and account associations?