Click here to Skip to main content
15,915,864 members
Home / Discussions / C#
   

C#

 
AnswerRe: Dot Net Deployment Pin
mav.northwind12-Jan-06 20:30
mav.northwind12-Jan-06 20:30 
GeneralRe: Dot Net Deployment Pin
chudapji13-Jan-06 0:51
chudapji13-Jan-06 0:51 
QuestionShow menu from form other than MDI form? Pin
MudkiSekhon12-Jan-06 18:19
MudkiSekhon12-Jan-06 18:19 
AnswerRe: Show menu from form other than MDI form? Pin
Luis Alonso Ramos12-Jan-06 18:24
Luis Alonso Ramos12-Jan-06 18:24 
GeneralRe: Show menu from form other than MDI form? Pin
MudkiSekhon12-Jan-06 18:31
MudkiSekhon12-Jan-06 18:31 
GeneralRe: Show menu from form other than MDI form? Pin
Luis Alonso Ramos12-Jan-06 18:37
Luis Alonso Ramos12-Jan-06 18:37 
GeneralRe: Show menu from form other than MDI form? Pin
MudkiSekhon12-Jan-06 19:04
MudkiSekhon12-Jan-06 19:04 
GeneralRe: Show menu from form other than MDI form? Pin
Luis Alonso Ramos13-Jan-06 5:20
Luis Alonso Ramos13-Jan-06 5:20 
If the second child window is of the same type (class, say ChildForm) as the first child, it should have the same menu. If it's a different type, then you must add the menu and code manually.

You should have something like this:
class MainForm : Form
{
    ...
 
    private void menuNewForm_Click(object sender, EventArgs e)
    {
        ChildFormWithMenu form = new ChildFormWithMenu();
        form.MdiParent = this;
        form.Show();
    }
}
 
class ChildFormWithMenu : Form
{
    ... (create MainMenu in the desginer and menu items) ...
 
    private void menuOneMoreForm_Click(object sender, EventArgs e)
    {
        // Note that for the second child to have the same menu and click
        // handlers, if must be of the same type as *this* form: ChildFormWithMenu
        ChildFormWithMenu form = new ChildFormWithMenu();
        form.MdiParent = this.MdiParent;
        form.Show();
    }
 
    private void menuNewFormWithoutMenu_Click(object sender, EventArgs e)
    {
        // Here we are creating a second form of a type different to this form.
        // It only will have a menu if you manually add it, but not the same
        // menu as this form has
        SomeOtherChildForm form = new SomeOtherChildForm();
        form.MdiParent = this.MdiParent;
        form.Show();
    }
}
I hope I have made myself clear!

MudkiSekhon wrote:
I want toread ur web page in English, I don't know Spanish... I am the reader of ur blog....


I'll respond there when the page opens Poke tongue | ;-P but having our web page in English is not a current priority. We have a lot of work for customers, and altough we sure would like to have it in English, we just don't have time for it right now. But thanks for stopping by! Smile | :)

-- LuisR



Luis Alonso Ramos
Intelectix - Chihuahua, Mexico

Not much here: My CP Blog!


The amount of sleep the average person needs is five more minutes. -- Vikram A Punathambekar, Aug. 11, 2005
QuestionCrystal Report Deployment in C# Pin
aarontan12-Jan-06 18:16
aarontan12-Jan-06 18:16 
AnswerRe: Crystal Report Deployment in C# Pin
CooperWu12-Jan-06 21:24
CooperWu12-Jan-06 21:24 
QuestionHttpWebRequest and SSL Authentication Pin
Skoder12-Jan-06 17:48
Skoder12-Jan-06 17:48 
QuestionDataGrid Issue, Please Help Pin
student_rhr12-Jan-06 16:41
student_rhr12-Jan-06 16:41 
AnswerRe: DataGrid Issue, Please Help Pin
Daniel Santillanes13-Jan-06 4:50
professionalDaniel Santillanes13-Jan-06 4:50 
AnswerRe: DataGrid Issue, Please Help Pin
Drew McGhie13-Jan-06 5:49
Drew McGhie13-Jan-06 5:49 
GeneralRe: DataGrid Issue, Please Help Pin
student_rhr13-Jan-06 6:35
student_rhr13-Jan-06 6:35 
GeneralRe: DataGrid Issue, Please Help Pin
student_rhr13-Jan-06 6:53
student_rhr13-Jan-06 6:53 
QuestionGenerics and the form designer in VS2005 Pin
Luis Alonso Ramos12-Jan-06 16:26
Luis Alonso Ramos12-Jan-06 16:26 
GeneralRe: Generics and the form designer in VS2005 Pin
Luis Alonso Ramos12-Jan-06 19:01
Luis Alonso Ramos12-Jan-06 19:01 
QuestionGenerate exe file from the C# program Pin
tadung12-Jan-06 15:04
tadung12-Jan-06 15:04 
AnswerRe: Generate exe file from the C# program Pin
Christian Graus12-Jan-06 15:12
protectorChristian Graus12-Jan-06 15:12 
GeneralRe: Generate exe file from the C# program Pin
tadung12-Jan-06 15:55
tadung12-Jan-06 15:55 
GeneralRe: Generate exe file from the C# program Pin
Christian Graus12-Jan-06 15:56
protectorChristian Graus12-Jan-06 15:56 
GeneralRe: Generate exe file from the C# program Pin
tadung12-Jan-06 15:58
tadung12-Jan-06 15:58 
QuestionSearch and Replace in Word Pin
CliffAnderson12-Jan-06 13:55
CliffAnderson12-Jan-06 13:55 
AnswerRe: Search and Replace in Word Pin
Nick Parker12-Jan-06 14:19
protectorNick Parker12-Jan-06 14:19 

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.