Click here to Skip to main content
15,924,036 members
Home / Discussions / C#
   

C#

 
GeneralRe: How to send/recieve objects with sockets? Pin
Chesnokov Yuriy31-Oct-09 4:41
professionalChesnokov Yuriy31-Oct-09 4:41 
GeneralRe: How to send/recieve objects with sockets? Pin
harold aptroot31-Oct-09 5:20
harold aptroot31-Oct-09 5:20 
QuestionRe: How to send/recieve objects with sockets? Pin
Chesnokov Yuriy31-Oct-09 8:55
professionalChesnokov Yuriy31-Oct-09 8:55 
QuestionGiving range to Run time end and start date parameter Pin
haleemasher30-Oct-09 23:53
haleemasher30-Oct-09 23:53 
QuestionUsing Connectionstring Pin
haleemasher30-Oct-09 23:52
haleemasher30-Oct-09 23:52 
AnswerRe: Using Connectionstring Pin
OriginalGriff31-Oct-09 0:46
mveOriginalGriff31-Oct-09 0:46 
GeneralRe: Using Connectionstring Pin
Keith Barrow31-Oct-09 3:03
professionalKeith Barrow31-Oct-09 3:03 
QuestionHow to access mdi parent's menustrip items from a child form [modified] Pin
idan_bismut30-Oct-09 21:58
idan_bismut30-Oct-09 21:58 
I have been trying to figure something for last couple of hours, but i'm unable to solve it & need some help.

I have project with 2 forms:
Form1 - MDI container
child_form1 - parent set to Form1

on menu_form i have MenuStrip called "MenuStrip1" and item called "item1".

on the item1 i have following code:
private void item1_Click(object sender, EventArgs e)
        {
            child_form1 cf1 = new child_form1();
            cf1.MdiParent = this;
            cf1.Show();
        }


now, for problem, i want to be able to modify Form1 menustrip items from the child menu. (specifically i want to uncheck the item1 when form is closed, but for the argument sake i just need to get proper handle/pointer to menu item).

So i've tried doing something like this:
Form main_form = this.MdiParent;
main_form.Controls["menustrip1"].Controls["item1"].Checked = false;


but it seems i can only get pointer/handle to the menustrip as a whole, but not to the item itself.
main_form.Controls["item1"] is not valid pointer
main_form.Controls["menustrip1"].Items does not exists

Am i missing something ??
How do i get handle to form's menustrip item(s) from another child form ?

Would appreciate any help in resolving the issue...

EDIT:
i managed to solve the problem myself, leaving msg as it might help others with same problem.

modified on Saturday, October 31, 2009 4:38 AM

AnswerRe: How to access mdi parent's menustrip items from a child form Pin
idan_bismut30-Oct-09 22:37
idan_bismut30-Oct-09 22:37 
GeneralRe: How to access mdi parent's menustrip items from a child form Pin
OriginalGriff30-Oct-09 23:37
mveOriginalGriff30-Oct-09 23:37 
GeneralRe: How to access mdi parent's menustrip items from a child form Pin
idan_bismut31-Oct-09 3:47
idan_bismut31-Oct-09 3:47 
GeneralRe: How to access mdi parent's menustrip items from a child form Pin
Member 1312346617-May-17 20:20
Member 1312346617-May-17 20:20 
QuestionHow to Register mshtml dll in to GAC ? Urgent. Pin
Jacobb Michael30-Oct-09 20:29
Jacobb Michael30-Oct-09 20:29 
AnswerRe: How to Register mshtml dll in to GAC ? Urgent. Pin
Christian Graus30-Oct-09 20:32
protectorChristian Graus30-Oct-09 20:32 
GeneralRe: How to Register mshtml dll in to GAC ? Urgent. Pin
Jacobb Michael30-Oct-09 20:43
Jacobb Michael30-Oct-09 20:43 
AnswerRe: How to Register mshtml dll in to GAC ? Urgent. Pin
Jacobb Michael31-Oct-09 0:52
Jacobb Michael31-Oct-09 0:52 
GeneralRe: How to Register mshtml dll in to GAC ? Urgent. Pin
Christian Graus31-Oct-09 0:53
protectorChristian Graus31-Oct-09 0:53 
QuestionHow to monitor the speed of writting into or reading out from the hard disk? Pin
sinron30-Oct-09 20:17
sinron30-Oct-09 20:17 
AnswerRe: How to monitor the speed of writting into or reading out from the hard disk? Pin
Christian Graus30-Oct-09 20:33
protectorChristian Graus30-Oct-09 20:33 
GeneralRe: How to monitor the speed of writting into or reading out from the hard disk? Pin
sinron30-Oct-09 23:07
sinron30-Oct-09 23:07 
GeneralRe: How to monitor the speed of writting into or reading out from the hard disk? Pin
Christian Graus31-Oct-09 0:54
protectorChristian Graus31-Oct-09 0:54 
GeneralRe: How to monitor the speed of writting into or reading out from the hard disk? Pin
Eddy Vluggen31-Oct-09 1:04
professionalEddy Vluggen31-Oct-09 1:04 
Questionis this a cache problem or what? Pin
niranjanR30-Oct-09 18:22
niranjanR30-Oct-09 18:22 
AnswerRe: is this a cache problem or what? Pin
Christian Graus30-Oct-09 19:17
protectorChristian Graus30-Oct-09 19:17 
GeneralRe: is this a cache problem or what? Pin
niranjanR30-Oct-09 19:44
niranjanR30-Oct-09 19:44 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.