Is there a method to retrieve the file name of a class?
<p>Is there a method to retrieve the file name of a class?</p>

<p>Specifically I would like to create a static method (CreateLink) in a base class (BasePage) to automatically return the path and filename of the page called.</p>

<p>I code in .C# ASP.NET</p>

<pre><code>private const string TEMPLATE =
    "~/One.aspx";

public static HyperLink CreateLink()
{
    HyperLink link = new HyperLink();
    link.Text = "Click here";
    link.NavigateUrl = String.Format(TEMPLATE);
    return link;
}
</code></pre>

<p>Is it possible to avoid the use of TEMPLATE hardcoded variable? Is it possible to retrieve the One.aspx path from file name and location?</p>
