XMLHTTP send, Calling NAV webservice from NAV

Benno67
Member Posts: 39
Hi All!
We have got a fuzzy problem with xmlhttp.send.
This message is for C/AL programmers:
The call to member send failed. msxml3.dll returned the following message:
The download of the specified resource has failed.
Why is msxml3 used?, both 3 and 6 are installed, the automation object for the xmlhttp variable is Microsoft XML v6???
Tryed tot change the variable to Microsoft XML v3, but gave the same error.
As examples we used Freddy's blog, and checked it against Rashed Job que sample. Both the same principle.
Checked is also on a local installation, same result.
Benno
We have got a fuzzy problem with xmlhttp.send.
This message is for C/AL programmers:
The call to member send failed. msxml3.dll returned the following message:
The download of the specified resource has failed.
Why is msxml3 used?, both 3 and 6 are installed, the automation object for the xmlhttp variable is Microsoft XML v6???
Tryed tot change the variable to Microsoft XML v3, but gave the same error.
As examples we used Freddy's blog, and checked it against Rashed Job que sample. Both the same principle.
Checked is also on a local installation, same result.
Benno
0
Answers
-
I have sometimes had this issue if using 'Microsoft XML, v6.0'.ServerXMLHTTP on a client or 'Microsoft XML, v6.0'.XMLHTTP on a server.
Have solved this issue this wayIF ISSERVICETIER THEN BEGIN IF ISCLEAR(WinHTTPServer) THEN CREATE(WinHTTPServer,TRUE,FALSE); WinHTTPServer.open('GET',URL,FALSE); WinHTTPServer.send(''); IF WinHTTPServer.status <> 200 THEN ERROR(Text007,WinHTTPServer.status,WinHTTPServer.statusText); DOMDocument.load(WinHTTPServer.responseXML); CLEAR(WinHTTPServer); END ELSE BEGIN IF ISCLEAR(WinHTTP) THEN CREATE(WinHTTP,TRUE,FALSE); WinHTTP.open('GET',URL,FALSE); WinHTTP.send(''); IF WinHTTP.status <> 200 THEN ERROR(Text007,WinHTTP.status,WinHTTP.statusText); DOMDocument.load(WinHTTP.responseXML); CLEAR(WinHTTP); END;
________________________________
Gunnar Gestsson
Microsoft Certified IT Professional
Dynamics NAV MVP
http://www.dynamics.is
http://Objects4NAV.com0 -
Thank you Gunnar,
I solved the problem, apparently, msxml3 has a problem on a / instead of a \ in the username…
Stupid mistake.
Still do not understand why msxml3 is used.
Benno0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions