You need to sign in to do that
Don't have an account?
office tool kitを使ったカスタムオブジェクトへのクエリ実行
Office Tol l Kitを使ってカスタムオブジェクトにクエリを実行したところ、
『SoapQueryResultSetParser::BodyEndElement failed to set field:urn:sobject.partner.soap.sforce.com!type』の
エラーが出ます。
標準オブジェクトに変更すると正常終了します。
メソッドは下記のとおりです。
カスタムオブジェクトへのクエリ実行方法が間違っているのでしょうか。
Public Function Test_Query(ByVal pUserName, ByVal pPassword)
On Error GoTo Er_Test_Query
Test_Query = False
Dim sfdc As Variant
Dim loginResult As Variant
Dim queryResult As Variant
Dim queryResultSize As Variant
Dim sfdcTable As String
Set sfdc = CreateObject("SForceOfficeToolkit4.SforceSession4")
sfdc.SetServerUrl (cURL & "/services/Soap/universal/")
loginResult = sfdc.Login(pUserName, pPassword)
sfdcTable = "XXX__c"
Set queryResult = sfdc.Query("select id, ownerid from " & _
sfdcTable & " where name like 'A%'", False)
queryResultSize = queryResult.Size 'Just so I can see in the
Test_Query = True
Exit Function
Er_Test_Query:
MsgBox Err.Description, vbOKOnly + vbCritical, "Er_Test_Queryメソッド"
End Function
Hi,
I am trying to execute the same code but i get an error popup as "Cannot create automation object" on the line Set sfdc = CreateObject("SForceOfficeToolkit4.SforceSession4").
Please let me know why this error and how should i proceed.