Solved

How do I Remove MDI title bar from the form when my child window is maximized?

Posted on 2008-10-11
3
891 Views
Last Modified: 2011-10-19
Hi folks...
I've an application like notepad, and when I click in a new document link..
The form open an MDI child in forwindowstate = maximized
The MDI child open a new menu bar above my application menu.

i want to remove the MDI child menu bar.

This is my code

            mdiChild = new Form();
            mdiChild.Text = "Document" + count.ToString();

            mdiChild.MaximizeBox = false;
            mdiChild.MinimizeBox = false;
            mdiChild.StartPosition = FormStartPosition.CenterScreen;
            mdiChild.ControlBox = false;
            mdiChild.ShowIcon = false;    
            mdiChild.MdiParent = this;
            editTextBox = new TextBox();
            editTextBox.Multiline = true;
            editTextBox.Dock = DockStyle.Fill;
            mdiChild.Controls.Add(editTextBox);
            mdiChild.WindowState = FormWindowState.Maximized;
            mdiChild.FormBorderStyle = FormBorderStyle.None;            
            mdiChild.Show();

Please check the screenshot.
Thanks everybody for your help
0
Comment
Question by:nkoriginal
  • 2
3 Comments
 
LVL 26

Accepted Solution

by:
Anurag Thakur earned 500 total points
ID: 22696526
I have a VB.NET sample for the same issue
Please read comment No. ID:21283382 by author:VBRocks which tells how to solve the problem
http://www.experts-exchange.com/Programming/Languages/.NET/Q_23294648.html
0
 
LVL 5

Author Comment

by:nkoriginal
ID: 22699677
Thanks Ragi for your answer. but i tried the information in that link, and it doesn't work. also I checked that page before post my question here, but i dont know why it doesn't work.

Do you know another way??

thanks
0
 
LVL 5

Author Comment

by:nkoriginal
ID: 22704307
Ragi, I tried the information in that link, in different way and it worked!
Thanks

By the way, if somebody want the code in C# is:


        private void Form2_Resize(object sender, EventArgs e)
        {
 
            if (this.WindowState == FormWindowState.Maximized)
            {
                this.FormBorderStyle = FormBorderStyle.None;
            }
            else
            {
                this.FormBorderStyle = FormBorderStyle.Sizable;
            }
 
        }

Open in new window

0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Data is not showing from images 15 47
What .NET URL re-routing tool did I use? 2 53
SQL Login 17 48
System.Speech 2 26
Extention Methods in C# 3.0 by Ivo Stoykov C# 3.0 offers extension methods. They allow extending existing classes without changing the class's source code or relying on inheritance. These are static methods invoked as instance method. This…
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…

816 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now