VB.NET :
Dim name as string = System.IO.Path.GetFileName(Request.ServerVariables("SCRIPT_NAME"))
C# :
string name = System.IO.Path.GetFileName(Request.ServerVariables["SCRIPT_NAME"]);
If you need to get it in codebehind, use HttpContext.Current
Juan T. Llibre, asp.net MVP
aspnetfaq.com :
http://www.aspnetfaq.com/
asp.net faq :
http://asp.net.do/faq/
foros de asp.net, en español :
http://asp.net.do/foros/
===================================
ad said:
I am use VS2005 to develop a web application.
How can I get the page name(the name of .aspx file) of it self in the page class?