|
Home > Archive > IIS Server > November 2004 > GetObject("IIS://LocalHost/W3SVC") -- Access denied when called from DLL
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
GetObject("IIS://LocalHost/W3SVC") -- Access denied when called from DLL
|
|
| Tim Gorgs 2004-11-29, 7:51 am |
| Hi all,
I have a problem which has been mentioned a couple of times in a
similar way, but not exactly as what it appears to be like with my
system.
I have a Visual-Basic ActiveX-DLL, which is correctly registered on
the system. But whenever I call the DLL-function which contains the
"GetObject("IIS://...") line, I get the "access denied" error.
When I debug the code in the Visual Basic IDE, everything works fine.
When I try to run the code as a VBScript, no problems occur either.
I really don't understand why it doesn't work within the DLL which
runs under the same (mine) account as the VB IDE and the VBScript do.
I could understand if it would work with all three methods or with
none, but this is all a bit mixed up...
Any help is very appreciated,
thank you
Tim
| |
| [Tony Devere] 2004-11-29, 5:54 pm |
| Where do you call the dll function from when it fails?
Thank you,
Tony DeVere [MSFT]
Microsoft IIS
Newsgroup Support
tdevere@online.microsoft.com
"Please do not send email directly to this alias. This is our online
account name for newsgroup participation only."
This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use. © 2001 Microsoft Corporation. All rights
reserved.
| |
| Ben Strackany 2004-11-30, 6:20 pm |
| Are you calling this DLL from an ASP or ASP.NET page? If so, you will need
to run the DLL as an account with correct permissions. Let's say it's your
account. You't can just set the anonymous user of the page to your
account -- that won't pass enough information to authenticate against the
ADSI objects.
Instead, throw the ActiveX DLL into a COM+ Server Application, and set the
identity of that application to your account. Then it should execute with
the correct permissions.
--
Ben Strackany
www.developmentnow.com
<a href="http://www.developmentnow.com">dn</a>
"Tim Gorgs" <google@supertimmy.com> wrote in message
news:afa954a3.0411290539.137ee099@posting.google.com...
> Hi all,
>
> I have a problem which has been mentioned a couple of times in a
> similar way, but not exactly as what it appears to be like with my
> system.
>
> I have a Visual-Basic ActiveX-DLL, which is correctly registered on
> the system. But whenever I call the DLL-function which contains the
> "GetObject("IIS://...") line, I get the "access denied" error.
>
> When I debug the code in the Visual Basic IDE, everything works fine.
> When I try to run the code as a VBScript, no problems occur either.
>
> I really don't understand why it doesn't work within the DLL which
> runs under the same (mine) account as the VB IDE and the VBScript do.
> I could understand if it would work with all three methods or with
> none, but this is all a bit mixed up...
>
> Any help is very appreciated,
>
> thank you
>
> Tim
|
|
|
|
|