| Author |
Loading an ActiveX DLL
|
|
| Andrew Chalk 2004-12-17, 2:49 am |
| Why would the following code execute in VB6 but hang indefinately when
exectuted in an ASP 3.0 page?
Set VLReceive = CreateObject("VLCTI.VLReceive")
This line is invoked in the following context:
<%
Dim VLReceive
Set VLReceive = CreateObject("VLCTI.VLReceive")
Set VLReceive = Nothing
%>
Is it the setup of the virtual directory or something?
Many thanks.
| |
| Aaron [SQL Server MVP] 2004-12-17, 5:52 pm |
| Tough to tell without understanding what the object does.
--
http://www.aspfaq.com/
(Reverse address to reply.)
"Andrew Chalk" <achalk@XXXmagnacartasoftware.com> wrote in message
news:ODSgD3$4EHA.3120@TK2MSFTNGP12.phx.gbl...
> Why would the following code execute in VB6 but hang indefinately when
> exectuted in an ASP 3.0 page?
>
> Set VLReceive = CreateObject("VLCTI.VLReceive")
>
> This line is invoked in the following context:
> <%
> Dim VLReceive
> Set VLReceive = CreateObject("VLCTI.VLReceive")
> Set VLReceive = Nothing
> %>
>
> Is it the setup of the virtual directory or something?
>
> Many thanks.
>
>
| |
| Andrew Chalk 2004-12-17, 5:52 pm |
| The object works in VB6 and on a .HTM web page. This problem is ASP-specific
I think. I wrote the object inVC++ v6.0 but cannot find a way to get the
debugger to break inside it when it is loaded from an ASP page.
- Andrew
"Aaron [SQL Server MVP]" <ten.xoc@dnartreb.noraa> wrote in message
news:%23GJXIUE5EHA.1300@TK2MSFTNGP14.phx.gbl...
> Tough to tell without understanding what the object does.
>
> --
> http://www.aspfaq.com/
> (Reverse address to reply.)
>
>
>
>
> "Andrew Chalk" <achalk@XXXmagnacartasoftware.com> wrote in message
> news:ODSgD3$4EHA.3120@TK2MSFTNGP12.phx.gbl...
>
>
| |
| Aaron [SQL Server MVP] 2004-12-17, 5:52 pm |
| > The object works in VB6 and on a .HTM web page. This problem is
ASP-specific
> I think.
I didn't object to that.
However, to help determine WHY it might be a problem in ASP, it would help
to know WHAT the object does. For example, ASP by default runs in the
context of IUSR_MachineName, which has a very different set of security
credentials than you do when you run an HTML page or VB application.
--
http://www.aspfaq.com/
(Reverse address to reply.)
| |
| Andrew Chalk 2004-12-17, 5:52 pm |
| Fair enough. The control:
1) attempts to instantiate a Winsock object and connect to a remote host. It
transfers some data with that host and then closes the socket;
2) It attempts local file I/O to write a log of its actions;
I looked at http://support.microsoft.com/?kbid=198432 and gave
IUSR_MachineName the Registry Value Permissions alluded to therein. I think
your emphasis on a 'permissions' problem is along the right lines. However,
what permissions and how do I change them? I'm prepared to give
IUSR_MachineName wide open machine access for debugging purposes if
necessary.
Thanks,
- Andrew
"Aaron [SQL Server MVP]" <ten.xoc@dnartreb.noraa> wrote in message
news:e9qOTRF5EHA.2804@TK2MSFTNGP15.phx.gbl...
> ASP-specific
>
> I didn't object to that.
>
> However, to help determine WHY it might be a problem in ASP, it would help
> to know WHAT the object does. For example, ASP by default runs in the
> context of IUSR_MachineName, which has a very different set of security
> credentials than you do when you run an HTML page or VB application.
>
> --
> http://www.aspfaq.com/
> (Reverse address to reply.)
>
>
| |
| Aaron [SQL Server MVP] 2004-12-17, 5:52 pm |
| > 1) attempts to instantiate a Winsock object and connect to a remote host.
It
> transfers some data with that host and then closes the socket;
Can you use MSXML2.ServerXMLHTTP for that? (See http://www.aspfaq.com/2173)
> 2) It attempts local file I/O to write a log of its actions;
IUSR_MachineName will need write/change permissions to this folder.
To test the permissions theory, you can temporarily add IUSR_MachineName to
the local Administrators group.
--
http://www.aspfaq.com/
(Reverse address to reply.)
| |
| Andrew Chalk 2004-12-17, 5:52 pm |
| Bingo! You're a genius. It was a permissions issue. Now the page
runs..exactly once. Apparently, I have a second problem of not freeing all
resources when I set the reference to 'nothing'. I'm looking into that now.
Many thanks,
- Andrew
"Aaron [SQL Server MVP]" <ten.xoc@dnartreb.noraa> wrote in message
news:enbXozF5EHA.824@TK2MSFTNGP11.phx.gbl...
host.[vbcol=seagreen]
> It
>
> Can you use MSXML2.ServerXMLHTTP for that? (See
http://www.aspfaq.com/2173)
>
>
> IUSR_MachineName will need write/change permissions to this folder.
>
> To test the permissions theory, you can temporarily add IUSR_MachineName
to
> the local Administrators group.
>
> --
> http://www.aspfaq.com/
> (Reverse address to reply.)
>
>
| |
| Egbert Nierop \(MVP for IIS\) 2004-12-18, 7:46 am |
| "Andrew Chalk" <achalk@XXXmagnacartasoftware.com> wrote in message
news:u58BZMI5EHA.3908@TK2MSFTNGP12.phx.gbl...
> Bingo! You're a genius. It was a permissions issue. Now the page
> runs..exactly once. Apparently, I have a second problem of not freeing all
> resources when I set the reference to 'nothing'. I'm looking into that
> now.
hi,
do not forget, that you should not base solution within ASP or a IIS context
on wininet api. The winsock control does, and it has thread problems which
at its turn can lead to leaks. Instead, base your solution on the WinHTTP
5.x Api.
http://msdn.microsoft.com/library/e....asp?frame=true
> Many thanks,
>
> - Andrew
>
>
> "Aaron [SQL Server MVP]" <ten.xoc@dnartreb.noraa> wrote in message
> news:enbXozF5EHA.824@TK2MSFTNGP11.phx.gbl...
> host.
> http://www.aspfaq.com/2173)
> to
>
>
| |
| Andrew Chalk 2004-12-18, 5:48 pm |
| Thanks. I am using the Win 32 SDK WinSock API so it should not have these
problems.
Regards,
- Andrew
"Egbert Nierop (MVP for IIS)" <egbert_nierop@nospam.invalid> wrote in
message news:e5VF69N5EHA.3124@TK2MSFTNGP11.phx.gbl...
> "Andrew Chalk" <achalk@XXXmagnacartasoftware.com> wrote in message
> news:u58BZMI5EHA.3908@TK2MSFTNGP12.phx.gbl...
all[vbcol=seagreen]
> hi,
>
> do not forget, that you should not base solution within ASP or a IIS
context
> on wininet api. The winsock control does, and it has thread problems which
> at its turn can lead to leaks. Instead, base your solution on the WinHTTP
> 5.x Api.
>
http://msdn.microsoft.com/library/e....asp?frame=true
>
IUSR_MachineName[vbcol=seagreen]
>
|
|
|
|