hello again,
sorry about another post but im new to OOP and i am having trouble understanding how i can access a variable from one class from a different class.
I have a class
then in my messsage class i haveCode:public class Main : System.Web.UI.Page { public string loadFile = " "; . . public void Page_Load(object sender, System.EventArgs e) { loadFile = "test"; }
i have access to the variable "loadFile" but it doesnt seem to grab the text out of the string. OOP is starting to frustrate me >.<Code:public class Message : System.Web.UI.Page { Private void Page_Load(object sender, System.EventArgs e) { Main mc = new Main(); StreamReader sr = new StreamReader(mc.loadFile); . . }
Thanks again guys



LinkBack URL
About LinkBacks


