cancel
Showing results for 
Search instead for 
Did you mean: 

DI API Recordset Value HRESULT: 0x80010105 (RPC_E_SERVERFAULT)) only on Release x64

yuvalb1
Explorer
0 Kudos
783

Very basic code:

 var rs = Company.GetBusinessObject(BoObjectTypes.BoRecordset);
            string sqlStr = "select top 1 DecSep, PriceDec, QtyDec, SumDec, RateDec, MeasureDec, PercentDec, ThousSep, MainCurncy from OADM";
            rs.DoQuery(sqlStr);
            DecSep = rs.Fields.Item("DecSep").Value.ToString();
            ThousSep = rs.Fields.Item("ThousSep").Value.ToString();
            if (rs.Fields.Item("SumDec").Value.ToString() != "") SumDec = (short)rs.Fields.Item("SumDec").Value;
            if (rs.Fields.Item("PriceDec").Value.ToString() != "") PriceDec = (short)rs.Fields.Item("PriceDec").Value;
            if (rs.Fields.Item("RateDec").Value.ToString() != "") RateDec = (short)rs.Fields.Item("RateDec").Value;
            if (rs.Fields.Item("QtyDec").Value.ToString() != "") QtyDec = (short)rs.Fields.Item("QtyDec").Value;
            if (rs.Fields.Item("MeasureDec").Value.ToString() != "") MeasureDec = (short)rs.Fields.Item("MeasureDec").Value;
            if (rs.Fields.Item("PercentDec").Value.ToString() != "") PercentDec = (short)rs.Fields.Item("PercentDec").Value;
            if (rs.Fields.Item("MainCurncy").Value.ToString() != "") MainCurr = rs.Fields.Item("MainCurncy").Value.ToString().TrimEnd();

In the last on I get System.Runtime.InteropServices.COMException: 'The server threw an exception. (Exception from HRESULT: 0x80010105 (RPC_E_SERVERFAULT))'

It only happends on certain computers and only if the application is "Release" x64,

works greate in Debug x64 and both Debug/Release x86

I just feel I'm wasting time and it's an environment issue I just can't figure out.

There's enough RAM on the computer, I removed both DI API 32 and 64 bit, deleted all user and windows temporary files, reinstalled both and still get the same error in the same exact line.

SAP B1 9.2 Patch Level 8

Accepted Solutions (0)

Answers (2)

Answers (2)

jangroetzner
Explorer
0 Kudos

We have the same problem now. How have you solved this?

Best regards

Jan Groetzner

yuvalb1
Explorer
0 Kudos

Seems we never got a fix for this.

If it's a big issue then yes, you should read with XML as this could solve your problem.

pedro_magueija
Active Contributor
0 Kudos

Hi Yuval,

You could try exporting the recordset data to XML and using the XML to load your properties.

That will limit the number of calls performed to the API.

Good luck.

Pedro Magueija

LinkedIn | Twitter | Blog