Results 1 to 8 of 8

Thread: [Resolved] Cannot map network drive!

Threaded View

  1. #1

    Thread Starter
    Member
    Join Date
    Oct 2006
    Posts
    53

    [Resolved] Cannot map network drive!

    Background:
    The website is run on a remote server. An asp-page handles access rights and list network drives. The asp-page is then redirected to an aspx-page with an ascx usercontrol. The usercontrol holds a dropdownlist with listed networkdrives as options to select.

    To achieve:
    Map selected driver.

    I have succeeded to map from the asp-page as long as the redirect to the aspx-page is disabled. If I redirect the mappping doesn't work.

    Now I have tryed several ways to map from the aspx-page

    1) reference to an interop dll made from an ocx that works on the asp-page. Doesn't work. I guess it's because it runs on server side.

    2) API functions from mpr.dll like WNetAddConnection2 function. Doesn't work. Same reason I believe though it works from an ordinary exe on the client.

    3) Using Diagnostic.Process.Start running net.exe. Same reason I believe (server side). Net.exe is registered and map drives from command window.

    4) Running a vb script doesn't work either. I believe vb scripts doesn't run with .net.

    5) Last try was with a javascript. Added "onchange" attribute to dropdownlist to run the javascript function. I can start Word with ActiveXobject("Word.Application") but I can't run net.exe whith ActiveXobject("Shell.Application").

    Any ideas how to solve this would be appreciated.
    Last edited by minor28; May 23rd, 2007 at 01:18 AM.

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