Write to a Network location from DNN

Discussion in 'ASP .Net' started by Brad, Mar 31, 2009.

  1. Brad

    Brad Guest

    Hi Guys,

    I'm trying to write to a network location but am getting access denied. This
    is on a test server running IIS6 on Vista SP1.

    System.Diagnostics.ProcessStartInfo psi = new
    System.Diagnostics.ProcessStartInfo("xcopy.exe");
    psi.UseShellExecute = false;
    psi.RedirectStandardOutput = true;
    psi.RedirectStandardInput = true;
    psi.RedirectStandardError = true;
    psi.WorkingDirectory = strWorkingDir;
    psi.Arguments = "/S /T /E \"" + src + "\" \"" + dst + "\"" ;

    // Start the process
    System.Diagnostics.Process proc =
    System.Diagnostics.Process.Start(psi);


    I have impersonate=true with a user account that has access to the
    desitnation folder.

    Not sure if I need to or not, but I am unable to change the account that
    "World Wide Web Publishing Service" is running as to "Network Service". I
    get an error "Error 1079: The account specified for this service is
    different from the account specified for other services running in the same
    process"

    What else do I need to do?
     
    Brad, Mar 31, 2009
    #1
    1. Advertising

  2. On Mar 31, 5:45 am, "Brad" <> wrote:
    > Hi Guys,
    >
    > I'm trying to write to a network location but am getting access denied. This
    > is on a test server running IIS6 on Vista SP1.
    >
    >             System.Diagnostics.ProcessStartInfo psi = new
    > System.Diagnostics.ProcessStartInfo("xcopy.exe");
    >             psi.UseShellExecute = false;
    >             psi.RedirectStandardOutput = true;
    >             psi.RedirectStandardInput = true;
    >             psi.RedirectStandardError = true;
    >             psi.WorkingDirectory = strWorkingDir;
    >             psi.Arguments = "/S /T /E \"" + src + "\" \"" + dst + "\"" ;
    >
    >             // Start the process
    >             System.Diagnostics.Process proc =
    > System.Diagnostics.Process.Start(psi);
    >
    > I have impersonate=true with a user account that has access to the
    > desitnation folder.
    >
    > Not sure if I need to or not, but I am unable to change the account that
    > "World Wide Web Publishing Service" is running as to "Network Service". I
    > get an error "Error 1079: The account specified for this service is
    > different from the account specified for other services running in the same
    > process"
    >
    > What else do I need to do?


    Brad, check this http://forums.asp.net/p/1339027/2713625.aspx#2713625
     
    Alexey Smirnov, Mar 31, 2009
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. asdf
    Replies:
    0
    Views:
    369
  2. Dmitry Duginov

    DNN custom module for surveys

    Dmitry Duginov, Oct 29, 2004, in forum: ASP .Net
    Replies:
    4
    Views:
    383
    Steven Cheng[MSFT]
    Nov 17, 2004
  3. ad

    What is DNN (DotNetNuke)

    ad, Mar 13, 2005, in forum: ASP .Net
    Replies:
    5
    Views:
    2,607
    patil.sandiip
    Dec 7, 2010
  4. Sara T.

    DNN and Access

    Sara T., Sep 21, 2005, in forum: ASP .Net
    Replies:
    3
    Views:
    1,925
    Richard Dudley
    Sep 21, 2005
  5. Sara T.

    DNN and MySQL

    Sara T., Sep 22, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    1,785
    Richard Dudley
    Sep 22, 2005
Loading...

Share This Page