Hello,
Does anybody know how to get window handle of parent window (the main
application window) in C#. I am trying to set mdiParent of a child window in
child's Load( ). I dont know how to set it to parent container control as
the child is created by an intermediary class that doesnt keep parent's
handle or reference.
regards,
anony 4 2463
In article <OU**************@TK2MSFTNGP11.phx.gbl>, Ayaz Ali wrote: Hello, Does anybody know how to get window handle of parent window (the main application window) in C#. I am trying to set mdiParent of a child window in child's Load( ). I dont know how to set it to parent container control as the child is created by an intermediary class that doesnt keep parent's handle or reference.
regards, anony
Pass it through.
No, just create a class Pool (singleton) and get the value from there.
Otherwise you will have to traverse the tree of parents. I don't
know how realistic it is, because I favored one of the two approaches above.
In article <OU**************@TK2MSFTNGP11.phx.gbl>, Ayaz Ali wrote: Hello, Does anybody know how to get window handle of parent window (the main application window) in C#. I am trying to set mdiParent of a child window in child's Load( ). I dont know how to set it to parent container control as the child is created by an intermediary class that doesnt keep parent's handle or reference.
regards, anony
Pass it through.
No, just create a class Pool (singleton) and get the value from there.
Otherwise you will have to traverse the tree of parents. I don't
know how realistic it is, because I favored one of the two approaches above.
In article <OU**************@TK2MSFTNGP11.phx.gbl>, Ayaz Ali wrote: Hello, Does anybody know how to get window handle of parent window (the main application window) in C#. I am trying to set mdiParent of a child window in child's Load( ). I dont know how to set it to parent container control as the child is created by an intermediary class that doesnt keep parent's handle or reference.
regards, anony
Regex might be an overkill in this case.
String object can split its contents:
String[] fields = "a,b,c,d,ef,gh,ikl".Split(',');
In article <OU**************@TK2MSFTNGP11.phx.gbl>, Ayaz Ali wrote: Hello, Does anybody know how to get window handle of parent window (the main application window) in C#. I am trying to set mdiParent of a child window in child's Load( ). I dont know how to set it to parent container control as the child is created by an intermediary class that doesnt keep parent's handle or reference.
regards, anony
Regex might be an overkill in this case.
String object can split its contents:
String[] fields = "a,b,c,d,ef,gh,ikl".Split(','); This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Ayaz Ali |
last post by:
Hello,
Does anybody know how to get window handle of parent window (the main
application window) in C#. I am trying to set mdiParent of a child window in
child's Load( ). I dont know how to set it...
|
by: fragget |
last post by:
hi-
i have a custom control that can be dragged onto a form.
the control can be dragged around the form with the mouse.
i want to draw a selection box around my control when it is selected
to...
|
by: Samuel R. Neff |
last post by:
I'm trying to find a good way to handle Control.InvokeRequired without
duplicating four lines of code in every function/event. Typically
what I've seen in books is this:
If InvokeRequired Then...
|
by: lotus |
last post by:
HI All..
I'm realtively new to C#.
I have MainForm which includes Parent usercontol, and this parent
usercontrol also contains child usercontrol.
MainForm --> Parent usercontrol --> child...
|
by: hmm |
last post by:
Hi all
I have two problems:
Problem #1:
I'm using a .NET Form with the property 'FormBorderStyle' set to 'None'. The idea is to completely cover the area of that Form with a UserControl. In...
|
by: alwayssmiling |
last post by:
Hi,
In my application, In the main form tab control is there. For this im adding a tabpage which contains a user control, this usercontrol contains many windows controls and other userdefined...
|
by: Martin M. Pedersen |
last post by:
Hi,
I have a program where I read a lot of user data. How can I handle
the case where the user press control-d ?
Is it possible to disable control-d or re-open the cin ?
I have made a small...
|
by: gnewsgroup |
last post by:
In my user control, I would like to find a Label control in the parent
page (the page that uses my user control). I need to update that
Label.Text when something happens in the user control.
I...
|
by: mentor |
last post by:
The GridView in Cotent page cause an updating event, but the handling methond won't be executed. The Row Count of the GridView is Zero, but in fact it's not zero.
Why?
<asp:Content...
|
by: =?Utf-8?B?TWlrZSBDb2xsaW5z?= |
last post by:
I have a web app that when I click a menu, I load a control. On one of these
controls, I have a button that when clicked, I need to unload the control to
unload itself and load a different control...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
| |