Results 1 to 15 of 15

Thread: DLL works through VB, not through ASP?

  1. #1

    Thread Starter
    Addicted Member Sibby's Avatar
    Join Date
    Feb 2001
    Location
    Milwaukee, WI *The United States of America*
    Posts
    144

    Unhappy DLL works through VB, not through ASP?

    I have written a DDL that utilizes an OCX for zipping and unzipping ZIP files. I have accessed this DLL through another VB project (for testing) and it's working great. But when I try to access it through ASP it's not returning the correct value. I can access other functions through ASP just fine, but the method that accesses the OCX that should return a 1 (does when going through VB), returns a 0 through ASP!?

    What could I be doing wrong? If you want I can provide some code, just tell me what you'd like to see.

    Thanks in advance

    ::Sibby::
    If you can think it....you can code it....

  2. #2
    Frenzied Member andreys's Avatar
    Join Date
    Sep 2002
    Location
    Los Angeles
    Posts
    1,615
    Your OCX, which you are trying to access, has to be installed and registred on the server.

  3. #3

    Thread Starter
    Addicted Member Sibby's Avatar
    Join Date
    Feb 2001
    Location
    Milwaukee, WI *The United States of America*
    Posts
    144
    thanks for the reply andreys,

    actually I'm using IIS on my own machine for testing. So through VB and ASP they are both accessing the exact same DLL in the exact same place. Is there something more I have to do through IIS to get this to recognize it through my ASP page? If so, any info would be great. Thanks!
    If you can think it....you can code it....

  4. #4
    Frenzied Member andreys's Avatar
    Join Date
    Sep 2002
    Location
    Los Angeles
    Posts
    1,615
    It could be security issue for your browser. Go to Tools >Internet Options....>'Security' tab select Intranet and click on Custom level button. Enable everything for 'ActiveX controls and Plug-ins'

  5. #5

    Thread Starter
    Addicted Member Sibby's Avatar
    Join Date
    Feb 2001
    Location
    Milwaukee, WI *The United States of America*
    Posts
    144

    Angry

    sorry andreys, it wasn't the browser. I'm positive it's something with IIS but I don't know what to do. I've been at this same damn problem for 2 days now. I'm at the point here where I literally want to punch a ****in' hole through my monitor. Sure, maybe I'll die from electricution but at least I won't have to worry about **** anymore. Has anyone ever done this? Am I just an idiot? Back to banging my head, hopefully someone will come to the rescue.
    If you can think it....you can code it....

  6. #6
    Frenzied Member andreys's Avatar
    Join Date
    Sep 2002
    Location
    Los Angeles
    Posts
    1,615
    Is it possible to ZIP all requaried files and post it here or on any other sever where I can download it?
    I want to test it on my IIS.

  7. #7

    Thread Starter
    Addicted Member Sibby's Avatar
    Join Date
    Feb 2001
    Location
    Milwaukee, WI *The United States of America*
    Posts
    144
    I can. It'll take me a bit but I'll get it up here. Thanks
    If you can think it....you can code it....

  8. #8
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    Could it be a File Permissions issue? VB runs as you, but IIS/ASP runs as IUSR_ComputerName by default.
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  9. #9

    Thread Starter
    Addicted Member Sibby's Avatar
    Join Date
    Feb 2001
    Location
    Milwaukee, WI *The United States of America*
    Posts
    144
    Here is the project. I've included a readme.txt in there so you can setup the environment. Let me know what you find and if you have any questions.

    Thanks!
    Attached Files Attached Files
    If you can think it....you can code it....

  10. #10
    Frenzied Member andreys's Avatar
    Join Date
    Sep 2002
    Location
    Los Angeles
    Posts
    1,615
    I need some time to set it up. Wait.

  11. #11

    Thread Starter
    Addicted Member Sibby's Avatar
    Join Date
    Feb 2001
    Location
    Milwaukee, WI *The United States of America*
    Posts
    144
    Just to update you on what I've discovered. I've moved the zip files I was tring to process from a subfolder under my IIS home directly to the home folder and ran it and everything works fine! Now why can't I access the subfolders through IIS? Everything should be setup to cascade rights down through filters. I havn't worked with IIS much but it looks like I have everything correct.

    Still stumped
    If you can think it....you can code it....

  12. #12
    Frenzied Member andreys's Avatar
    Join Date
    Sep 2002
    Location
    Los Angeles
    Posts
    1,615
    Ok, I tryed to put dll and ocx on my PC and run on IIS- nothing happend. I got "cannot display page" message.
    Then I put dll and ocx (registred it of course) on my intranet server at work and tryed to run test.asp page - Same result NONE.
    And I think your problem with your dll. As I know in a DLL projects you not supost to use OCXs. You cannot run OCX on server side, it should be done on client site. But before it could be run on clients side your OCX component must be installed on client machine. So user will get message with the prompt to load and run OCX from www.anyname.com site.
    Your DLL uses OCX and this stops that dll to run on the server.
    The DLL files run on the server side, but your DLL uses OCX, which could not be run on the IIS.

  13. #13

    Thread Starter
    Addicted Member Sibby's Avatar
    Join Date
    Feb 2001
    Location
    Milwaukee, WI *The United States of America*
    Posts
    144

    Thumbs down

    Hey all,

    First of all, thanks to andreys who took the time to run my project and try and figure out what was going on.

    I figured out what my problem was......NOTHING! (well sort of). I (for some desperate reason) copied a different ZIP file to that folder I was processing in and whala! It worked? I was like ***? Eventually I figured out that if you COPY the files to the IIS subfolder it finds them no problem. If you MOVE them it doesn't? Does anyone know why this works this way? This little fluke cost me 2 days work and I'm pissed. I'd like to know why this is for future reference.

    ::Sibby::
    If you can think it....you can code it....

  14. #14
    Frenzied Member andreys's Avatar
    Join Date
    Sep 2002
    Location
    Los Angeles
    Posts
    1,615
    Happy for you, but still could not belive it. IS it works? How long time does it takes to display anything on the page?

  15. #15

    Thread Starter
    Addicted Member Sibby's Avatar
    Join Date
    Feb 2001
    Location
    Milwaukee, WI *The United States of America*
    Posts
    144
    Yeah, it works, but like I said, only if the files are COPIED to the subfolder in your IIS home directory. It loads pretty fast. It churns through about 50 zip files in a second or 2, and it also collects file names, file dates, and file sizes. I can finally start coding something new now! Thanks for all your help.
    If you can think it....you can code it....

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width