Similar Threads
1. A Question, Hiding Child frame in MDI App.
Hi, everybody.
I need to hide child frame in MDI app.
But, I will use document and view in the child frame.
So, I've got to hide the child frame with no destruction.
ShowWindow( SW_HIDE ) makes the child frame just minimize.
Is it possible to hide child frame in MDI app?
I need your helps.
Help me~
2. integration MDI child views from VC i VB into one MDI App
3. MDI frame & MDI child window questions
Hello fellow Newsgroupies,
When an MDI child window is maximized within its MDI frame window the
title of the child window is wrapped in square brackets and added to
the end of the frame windows title.
Is there anyway to prevent this from happening?
I want everything else to happen as normal except for the child title
to be added to the frame title.
Many thanks,
'Newsgroupie'
England
4. newbie question: embedding Python into a C++ app and calling app functions
5. Scope of Child Window in MDI app
I am writing an MDI app that uses a document manager class
to keep track of opened child windows. I want the user to
be able to close a child window, but then re-open the
window from the "Window" menu if they want.
What happens to the child window after it is closed? Even
though my document manager maintains the instance of the
child and displays the name in the menu, when I try to use
the show() method or the activate() method on a closed
child, nothing happens.
Can anyone help me with this?
Some of the code is below:
In the load event handler for the child, I register the
child with the following code-
DocumentManager.Current.RegisterDocumentView(this);
Here is the DocumentManager Class:
public class DocumentManager
{
public DocumentManager()
{}
private static DocumentManager current;
private ArrayList documents = new ArrayList();
public static DocumentManager Current
{get{return current;}}
public ArrayList Documents
{get{return documents;}}
[STAThread()] static void Main()
{
current = new DocumentManager();
///instantiate the parent window
PunchDocumentView view = new PunchDocumentView();
view.Show();
Application.Run();
public void RegisterDocumentView (frmChild view)
{
Documents.Add(view);
}
}
The popup event handler for the parent window creates the
menu with all documents currently in the manager:
private void menuWindow_Popup(object sender,
System.EventArgs e)
{
menuWindow.MenuItems.Clear();
int ordinal = 1;
foreach (frmChild view in
DocumentManager.Current.Documents)
{
WindowMenuItem item = new WindowMenuItem();
menuWindow.Menuitems.Add(item);
ordinal++;
And finally the WindowMenuItem class constructs the items
to be displayed in the menu. The overridden OnClick event
handler is where I am trying to display the closed form,
but it isn't working:
public class WindowMenuItem : System.Windows.Forms.MenuItem
{
public frmChild View;
public WindowMenuItem(int index, frmChild view)
{
View = view;
Text = string.Format("{0}{1}", index, View.Text)
}
protected override void OnClick(System.EventArgs e)
{
View.Show(); ///These 2 methods don't appear
View.Activate(); ///to do anything if the child
///is closed
}
}
6. How to access control in child form (MDI app) - CSharp/C#
7. Adding VB6 Forms(in an ActiveX DLL) to a C# app as MDI Child windows
I have a number of VB6 ActiveX DLL's that contain forms. The fornt end
is VB6 at this point and the forms are dispalyed as MDI child windows.
I am attempting to convert the front end to C# and would like to use
these forms.
I have been able to load the forms and set the parent, but the C# app
seems to hang once the form is added. The forms are modal.
I have seen a number of posts related to this topic. I am not sure
that this is the best method.
Any ideas or suggestions would be appreciated.
8. Windows Menu in MDI app. - CSharp/C#