check this below code is for textbox you can change it to checkbox as per your need
How to access textbox on parent form
http://social.msdn.microso
First, set the modifier of your textBox to internal (or public if the child form you are showing is from a different assembly) of your parent form to expose it, so other forms can have access to it by using the parent form's instance.
Then, from your ShowDialog call, do it this way:
Form fRoom = new RoomAllocator();
fRoom.ShowDialog(this);
To access the exposed textbox from RoomAllocator, all you have to do is, cast the Owner property value to the type of your parent form:
TextBox parentTextBox = ((ParentForm)this.Owner).t
parentTextBox.Text = "Textbox is updated from the child form";
Main Topics
Browse All Topics





by: daryalPosted on 2009-09-11 at 07:53:42ID: 25310129
Hello, uestions/7 17074/how- to-access- form- objec ts-from-an other-cs-f ile-in-c
Check here for answer;
http://stackoverflow.com/q