Problems with Dropping custom files on our server?

Results 1 to 2 of 2

Thread: Problems with Dropping custom files on our server?

  1. #1
    Join Date
    Dec 1969

    Default Problems with Dropping custom files on our server?

    I am trying to take variable values and create a file that has a random number which i generate on the fly, querystring values and also a .100 concatenated on the end. The problem is that I get a path not found error. My virtual folder for the web is on my desktop and the nfl/internet folder is off the root of c.<BR><BR>I am enclosing my code, can someone please take a peek. <BR><BR>Here is my code:<BR><BR>filetest1 = 1<BR>filetest2 = 1<BR><BR>while filetest1 =1<BR> randomize()<BR> random1 = Int((10000000 * Rnd) + 10000000)<BR> Set loginfile = Server.CreateObject("Scripting.FileSystemObject")< BR> logfile1 = "........
    flinternet\" & random1 & ".100"<BR> logfile2 = Server.MapPath(logfile1)<BR> If loginfile.FileExists(logfile2) Then<BR> filetest1=1<BR> Else<BR> filetest1=2<BR> End If<BR>Wend<BR><BR>wrfile = "........
    flinternet\" & random1 & ".100"<BR><BR>output1 = "sjnb4.asp?R=" & random1 & "&F=" & ferry1<BR><BR>Set info1 = Server.CreateObject("Scripting.FileSystemObject")< BR>infow = Server.MapPath(wrfile)<BR><BR>Set OutStream = info1.CreateTextFile(infow)<BR>OutStream.WriteLine ferry1<BR>OutStream.WriteLine date1

  2. #2
    David Forster Guest

    Default RE: Problems with Dropping custom files on our ser

    I think MapPath only works for files which are shared by the WWW service. try setting your logfile2 variable to ("C:
    flinternet\" & random1 & ".100") and see what happens.<BR><BR>If you know the physical path to your file, why are you using MapPath anyway, that&#039s all it does, isn&#039t 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