How to access a member or method to another page?

N

Nick

hi,
I have two page like this:
public partial class FormMessage : System.Web.UI.Page
{
public static void ShowSomething()
{
........
}
}

This is another page in a seperate cs file.
public partial class FormMessage : System.Web.UI.Page
{
public void Login()
{
....
FormMessage.ShowSomething(); // Here, it says, the name
"FormMessage" does not exist in the current context...
}
}

It is not like the 1.0 you can access anywhere in the same namespace?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,020
Latest member
GenesisGai

Latest Threads

Top