Reputation: 13487
I have a page that contains a static method like this:
public partial class _Default : System.Web.UI.Page
{
[WebMethod(EnableSession = true)]
public static string Aware()
{
return DateTime.Now.ToString();
}
}
How I can call this method from a Master Page?
Upvotes: 0
Views: 1000
Reputation: 26737
_Default.Aware()
as for any other static method
EX:
public partial class About : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
_Default.Aware();
}
}
Upvotes: 2