cancel
Showing results for 
Search instead for 
Did you mean: 

ABAP consume local file as web service

Former Member
0 Kudos

I am trying to consume a local file (file://c:/xxx.html) as a web service using method CL_HTTP_CLIENT=>CREATE_BY_URL.  When I do that, I get the 'ARGUMENT_NOT_FOUND' exception returned.  I know the file exists and when I launch  it from the Windows start menu, it launches fine and I see the JSON output that I am expecting when I try to call it from ABAP.  Is there another way to address the file using this - or another - method?

Asking the question from the complete opposite direction; I have ABAP logic looking to see if a HID device (i.e. - signature pad) is attached to my PC via USB.  My web developer has supplied me with the local web service that will tell me if the device is attached (the file mentioned above), but it is not working.  Is there a more direct way to query the presentation server / local PC to see if an individual device is attached?  I thought maybe I could find the device listed in the registry (so I could read it using CL_GUI_FRONTEND_SERVICES methods) but so far had no luck in finding it there.

Any help would be appreciated.

Thanks.

Accepted Solutions (0)

Answers (1)

Answers (1)

attila_mikulan
Employee
Employee
0 Kudos

Hi Will,

ARGUMENT NOT FOUND refers to SSL error. Are there any imported schemas in the WSDL file located on a HTTPS server? You can see that by opening the file in a text or XML editor: <xsd:import location="https://...">

If that's the case, download these files in a browser (check if they have further referenced files as well). Once all files are downloaded, update the references to relative URI (remove http://... just leave .xsd in the reference) and place everything in one folder.

You can also create a monolithic WSDL from these, see SAP KBA 2200995.

Cheers,

Attila

Former Member
0 Kudos

There is not a WSDL nor a web server.  I mentioned that the file is local on the PC.

Thank  you.