Click here to Skip to main content
15,744,304 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hello every body

Please help me please i have problem in
I have 3 forms,1 textbox in form1,1 textbox in form2.
in form3: I want to have a print button to print the text of textboxes in form1 & form2

please help me I'm new in C# please explain your answer thanks a lot.
Updated 31-Jul-12 19:56pm

You should use delegates to be able to query your other forms for the contents of their textboxes. Google delegates and read some articles on the topic, if you're new to C#, it's probably more complex than you'd like, and a forum answer won't cut it.
Share this answer
U can use a public function which returns string in form1

then in Form2
string Form1text = (GetForm1Window() as form1).functionName();
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900