Mappath Error?

Results 1 to 3 of 3

Thread: Mappath Error?

  1. #1
    Join Date
    Dec 1969

    Default Mappath Error?

    created a "send this page through email" as written in the<BR>article dated 12-15-99 Sending Web Articles through Email.<BR>I receive this following error?<BR>Server.MapPath() error &#039ASP 0173 : 80004005&#039 <BR>An invalid character was specified in the Path parameter for the MapPath method. <BR>wat could be the reason?<BR>please help.

  2. #2
    Gary Van Sluis Guest

    Default RE: Mappath Error?

    Please post your code so we can see the error in action.<BR>

  3. #3
    Join Date
    Dec 1969

    Default RE: Code for Error?

    Ref: 12/15/99 "Sending Articles Through Email<BR><BR>Const forReading = 1<BR>Dim objFSO, objOpenFile, strBody, iStart strLeft, strRight<BR><BR>Set objFSO = Server.CreateObject("Scripting.FileSystemObject")< BR><BR>&#039Get the refered URL<BR>strLeft = Request("URL")<BR><BR>&#039Hack off the "http://"<BR>strRight = Right(strLeft,Len(strLeft)-7)<BR><BR>&#039Find the first forward slash<BR>iStart = instr(1,strRight,"/")<BR><BR>&#039Grab everything to the right of the forward slash<BR>strRight = Right(strRight,Len(strRight)-iStart+1)<BR><BR>&#039Open the text file<BR>Set objOpenFile = objFSO.OpenTextFile(Server.MapPath(strRight), _<BR> ForReading)<BR><BR>one of the programmer has given code like this to remove<BR>the querystring which comes in the path.<BR><BR>If InStr(1,strRight,"?") &#062; 0 then<BR>strRight = Mid(strRight,1,InStr(1,strRight,"?") - 1)<BR>End If<BR><BR>but still it is not working.<BR><BR>send me code how to remove the querystrings which comes<BR>in the pathaddress. say like<BR> 0312<BR>i have written code to remove the http://<BR>but how to remove the query string which comes after<BR>default.asp.<BR><BR>awaiting your reply.<BR><BR>need the code please<BR><BR>Mathew.<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