Hi all,
i am trying to consume a function in a web service published in BC. In postman, I get this error:
In the WSDL, I can see tthat the function is published:
This is how the function looks like:
Must add that in this codeunit, I already have fucntions that are consumed without any problem. I'm afraid that the problem might be the comples type sent by parameter....
Answers
Something doesn't add up because looks like you are calling a OData v4 WS and this function is returning an XML, and in the other hand I don't think is possible to publish a codeunit like a OData WS.
How do you call the others functions in this codeunit that you consumed whitout any problem ?
Regards.
This is a call to a function in the same codeunit in BC:
The codeunit is published as SOAP, but as far as I know, this is the way to call to webService in BC no?
Anyway, i'm afraid that the main problem is the XMLPort parameter. If I quit it, I don't get the "resource not found" error.
Must say that the aim of this function, and that XMLPort, is to be the datasource of a datagrid in a C# webApp.
But now I have to use this text as datasource for the grid, so i assume I must convert it into XML
When I', trying the conversion, I get this classic error
Of course, seems that I must delete "@odata....." information
Yes, you get in return a json object with 2 properties ("@odata.context" and "value") and you need to get the "value" part that it's the XML.
Regards.
That it's what you are trying to do with the C# code, I guess that the datagrid will work with the XML, I really don't know.
Regards.