dtsrun in batch in ASP

Results 1 to 2 of 2

Thread: dtsrun in batch in ASP

  1. #1
    ProgrammerInGallows Guest

    Default dtsrun in batch in ASP

    I am attempting to run a batch importProduction.bat It contains the following code:<BR><BR>dtsrun /S unl-web /N ProdImport /U hhhhh /P hhhh<BR><BR>I am attempting to access it in ASP with the following code:<BR><BR>set FileSys = Server.CreateObject("Scripting.FileSystemObject")< BR><BR>Set WShShell = Server.CreateObject("WScript.Shell")<BR><BR>WShShe ll.Run "C:importproduction.bat", 1, True <BR><BR>if RetCode = 0 Then <BR>&#039no errors<BR>else<BR>Response.Write "Import Errors"<BR>end if <BR><BR>It is pretty basic but I cannot get it to work. It doesn&#039t error out but it also doens&#039t run the import. The IUSR account has access to read on this drive. I am aware that this is not secure, I am using only for testing purposes on this server for now.<BR><BR>Any Ideas will be greatly welcome

  2. #2
    Join Date
    Dec 1969

    Default See if this helps

    Try changing:<BR><BR>WShShell.Run "C:importproduction.bat", 1, True <BR><BR>to<BR><BR>WShShell.Run "CMD.com /c C:importproduction.bat", 1, True <BR><BR>

Posting Permissions

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