Hi there
I am somewhat stuck with calling a WebService from out of a VB App.
My Goal:
- Get a WebService invoked under MS - Access 2002, not using the
MS-SOAP-Toolkit but the .net - Framework
My Restrictions:
- The WebService is pure Java, running under WebSphere5.1
- The Request requires Basic Authentication and needs to be SSL
encrypted
What I achived:
- The ServerSide is running OK
- A Java-Client using ApacheSOAP is running OK
- My WSDL - File is OK
- I got a monitor set up that intercepts incoming requests and
forwards them to the actual server, calls from my VBA Code are OK
(correct SOAP-Requests)
Where I'm stuck:
- The HTTP-Post request has no Authentication-Information.
- In a second step I need the ssl cert, but I have not bothered about
that yet.
My approach so far:
---------------- SNIP -----------------
Const WS_URL = "BLA.wsdl" ' WSDL File stored lokally
Dim client As SOAPClient
Dim nResult As String
Set client = CreateObject("MSSOAP.SOAPClient")
Call client.mssoapinit(WS_URL)
client.ConnectorProperty("AuthUser") = "foo"
client.ConnectorProperty("AuthPassword") = "bar"
client.ConnectorProperty("UseSSL") = False
nResult = client.getNewIds("99999")
Debug.Print nResult
---------------- SNAP -----------------
This will end up in an "Not-Authenticated" error, as the Request is
somewhat like:
---------------- SNIP -----------------
POST /ONBSystem/services/ONBPort HTTP/1.1
SOAPAction: "urn:#orderGetNewOffer_Ids(duns)"
Content-Type: text/xml
User-Agent: SOAP Sdk
Host: localhost
Content-Length: 392
Connection: Keep-Alive
Cache-Control: no-cache
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<SOAP-ENV:Envelope
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Body>
<SOAPSDK1:getNewIds
xmlns:SOAPSDK1="http://someurl/orderinterface">
<duns>99999</duns>
</SOAPSDK1:getNewIds>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>---------------- SNAP -----------------
Which misses the "Authentication: Basic sdretwefasdfert=="
request-attribute.
Could anyone please push me into the right direction? I could not find
any samplecode, which lets me assume I'm doing all wrong and got the
wrong approach?