hi sir,
i have a textbox and loginbutton in first form and wen i click on a valid id in 1st textbox wch is in the database and click on loginbutton it should show the details of that id in the next form which consists of textboxes and a modify button i am unable to know how to do dis please help
Gangadhar619
0
Newbie Poster
Recommended Answers
Jump to PostCreate an instance of Second Form's object and request for message Show().
.... Form2 a=new Form2(); a.Show();
Jump to PostThis is actually a bit more tricky then its given credit. The problem is, when you run your first form, that is, in the program.cs file, you call Application.Run(new Form1); //or whatever the log in form is called.
It then becomes responsible for the thread, if …
Jump to Postyou need to call the close() method from inside the login form's code...
just add the line to this section
…//Open Main CRM Form CRMMain crmMainForm = new CRMMain(); crmMainForm.employee = employee; crmMainForm.Show(); [B]this.Close();[/B]//this will cause the login form //close after the main form is opened
All 11 Replies
kvprajapati
1,826
Posting Genius
Team Colleague
ddanbe
2,724
Professional Procrastinator
Featured Poster
Diamonddrake
397
Master Poster
ddanbe
commented:
Closing the main form can be tricky, you explained why,thanks!
+6
Sailor_Jerry
3
Junior Poster in Training
Diamonddrake
397
Master Poster
Sailor_Jerry
commented:
Helped correct my code
+4
Sailor_Jerry
3
Junior Poster in Training
Diamonddrake
397
Master Poster
Sailor_Jerry
3
Junior Poster in Training
Diamonddrake
397
Master Poster
Sailor_Jerry
3
Junior Poster in Training
Diamonddrake
397
Master Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.