I declared a public variable in my main form(startup form). then the user clicks on a button and a new form with a textbox appears. the user enters some string in the textbox and clicks a button to close the form. Now i have to show that string in the main form. how?
I cant write form1.label1.text=strresult because
'Object reference not set to an instance of the object'