Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 15
Default MSXML2.XMLHTTP: "Access is Denied" - works on IE 6 SP1 but not SP2

(question rephrased)

i have been using msxml2.xmlhttp object for a long time and never had any
trouble. my OS was XP SP1 and the browser was IE 6 SP-1, with no special
security adjusments needed at all. it just worked. my script would log me in
to my private web site and then fetch data and log out, very simple stuff.

the following code is an example (not wanting to disclose my website
particulars here - you can plug in any login page and you will get the same
result)


Dim objHTTP As Object
Set objHTTP = CreateObject("MSXML2.XMLHTTP")
usrnme = "test"
pwrd = "test"


logfl = "https://mysite.com/"
objHTTP.Open "POST", logfl, True
objHTTP.setRequestHeader "Keep-Alive", "300"
objHTTP.setRequestHeader "Connection", "Keep-Alive"
objHTTP.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
submurl = "uname=" & usrnme & "&Passwd=" & pwrd
objHTTP.send (submurl)
Do While objHTTP.ReadyState < 4
DoEvents
Loop

objHTTP.Open "GET", "http://mysite.com/datapage.htm", False

objHTTP.send


everything was fine until i upgraded to XP SP2. i *never* had any trouble
with the code above. but *now* i get an 'Access is Denied' error at the line
i placed the 's.

this is a little frustrating. you'd think when one develops something in an
older version that it would be good for all future versions.

anybody know how to get a formerly woking script to work again now that i am
using XP SP2 instead of XP SP1 (IE 6.0 SP2 vs IE SP1)?

i have tried:

Set objHTTP = CreateObject("MSXML2.XMLHTTP.2.6")
Set objHTTP = CreateObject("MSXML2.XMLHTTP.3.0")
Set objHTTP = CreateObject("MSXML2.XMLHTTP.5.0")

but i keep getting the same result.
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
"access denied" message when open Excel, MS 2007 piciu Excel Discussion (Misc queries) 1 February 12th 09 01:32 AM
MSXML2.XMLHTTP Works with IE6, IE6 SP 1 but not with IE6 SP 2 - wh p3plyr Excel Programming 1 April 17th 07 06:12 PM
I get "Access Denied" trying to open network files. BKirk Excel Discussion (Misc queries) 0 March 10th 07 12:40 AM
Excell files showing "Read Only" access denied Scott L Excel Programming 1 November 30th 04 12:27 AM
"Programmatic Access to be Denied" displays when running macro on excel in XP Stephen Fong Excel Programming 3 October 21st 03 09:19 AM


All times are GMT +1. The time now is 08:38 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"