C# Application

Associate
Joined
7 Aug 2008
Posts
302
Hey Lads,

I'm currently trying to pass data from one form to the other in C# (VS 2010).

The data in the first form contains generica data; firstname, lastname etc and I am trying to make it so when I press an edit button on Form1, it will load up the second form (Form2) and load the data that is currently in the textboxes in Form1 but enabled (so we can edit them as they are disabled by default to just enable browsing on Form1).

What is the easiest way to do this?

I've been trying to create an instance of a form and messing around with that but can't get it to work atm.

Any pointers?

Thanks,
Tom.
 
Hey lads.

Thanks for the replies.

I had to use seperate forms unfortunately as it was a requirement. However, I do agree it would probably make more sense to have them disabled by default then enabled when the Edit button was pressed. Got it sorted now anyway with me being able to save the new changes to a text file etc.

I used public static TextBox First = new TextBox();

As part of the code to swap data from one form to another if anyone was interested.

Cheers,
Tom.
 
Back
Top Bottom