Permission Denied error on http GET

S

simplybjm

Hello

I have a problem with an Infopath 2003 form. I have a number of
secondary data sources which I want to update on a button click. I am
getting an xml feed from a url and then updating the local table.
Everything works fine in design mode but when I publish the file (even
to the local machine) and run the form I get a permission denied
error. An extract of the code is:

Set filesys = CreateObject("Scripting.FileSystemObject")

' get the new data feed
url = "http://ipaddress/xmlfeed/codelist"
Set inet = CreateObject("Microsoft.XMLHTTP")
inet.open "GET",url,false
inet.send
sHTML = inet.responseText
If filesys.FileExists("c:\dir\codeist.xml") Then
filesys.DeleteFile "c:\dir\codeist.xml"
End If
Set filetxt = filesys.CreateTextFile("c:\dir\codelist.xml")
filetxt.Write sHTML
filetxt.Close

fyi
The form is fully trusted and signed with a valid certificate.
The ipaddress is of a machine on our local network
The secondary data sources are resource files that are refreshed on
load and after this update.

Any assistance would be much appreciated.

Thank You
 
S

simplybjm

Hello

I have a problem with an Infopath 2003 form. I have a number of
secondary data sources which I want to update on a button click. I am
getting an xml feed from a url and then updating the local table.
Everything works fine in design mode but when I publish the file (even
to the local machine) and run the form I get a permission denied
error. An extract of the code is:

Set filesys = CreateObject("Scripting.FileSystemObject")

' get the new data feed
url = "http://ipaddress/xmlfeed/codelist"
Set inet = CreateObject("Microsoft.XMLHTTP")
inet.open "GET",url,false
inet.send
sHTML = inet.responseText
If filesys.FileExists("c:\dir\codeist.xml") Then
filesys.DeleteFile "c:\dir\codeist.xml"
End If
Set filetxt = filesys.CreateTextFile("c:\dir\codelist.xml")
filetxt.Write sHTML
filetxt.Close

fyi
The form is fully trusted and signed with a valid certificate.
The ipaddress is of a machine on our local network
The secondary data sources are resource files that are refreshed on
load and after this update.

Any assistance would be much appreciated.

Thank You

Apologies cannot even cut and paste correctly. The files are
codelist.xml
Also the error is given on the inet.open "GET",url,false line
 
S

S.Y.M. Wong-A-Ton

Double-check your IE security settings to see what is set to "Disable". This
error can be caused by many things outside of InfoPath, so it might be best
to also do a Google search on "XMLHTTP permission denied".
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top