Help | Site Map
Connecting Tech Pros Worldwide
 
 
LinkBack Thread Tools
  #1  
Old July 19th, 2005, 01:06 PM
David C. Holley
Guest
 
Posts: n/a
Default Getting a ASP file name via VBScript

Is there a function in VBScript that will return the name of the file
that is currently being executed? Basically, I'm looking for a function
that I can use in code similar to this...


<% response.write "The name of this file is - " thisFile.fileName %>

which will result in

The name of this file is - home.asp

being displayed on the page with home.asp executes.

  #2  
Old July 19th, 2005, 01:06 PM
Chris Hohmann
Guest
 
Posts: n/a
Default Re: Getting a ASP file name via VBScript

"David C. Holley" <DavidCHolley@netscape.net> wrote in message
news:uyc0OtXMEHA.628@TK2MSFTNGP11.phx.gbl...[color=blue]
> Is there a function in VBScript that will return the name of the file
> that is currently being executed? Basically, I'm looking for a function
> that I can use in code similar to this...
>
>
> <% response.write "The name of this file is - " thisFile.fileName %>
>
> which will result in
>
> The name of this file is - home.asp
>
> being displayed on the page with home.asp executes.[/color]

Request.ServerVariables("SCRIPT_NAME")
http://msdn.microsoft.com/library/en...rvariables.asp


  #3  
Old July 19th, 2005, 01:06 PM
David Holley
Guest
 
Posts: n/a
Default Re: Getting a ASP file name via VBScript

Thank you and know for the code that I was thinking of...

session("go_pageRequested") =
Request.ServerVariables("SCRIPT_NAME")

session("go_pageAlternate") = "reservationRequest_Error.asp"

My soon-to-be custom error page will automatically log the page the
encountered the error and then attempt to redirect to the indicated
page.

David H

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
 

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over network members.
Post your question now . . .
It's fast and it's free

Popular Articles