Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to create navigation inside program Form
    primarykey
    data
    text
    <p>Warning! This is noob question probably! Sorry in advance.</p> <p>I'm learning C# (using MS Studio 2013) and I'm having hard time creating some kind of decent navigation in simple desktop program.</p> <p>Basically what I want is this: MenuStrip with options like "calculate something", "Calculate somethingelse"... and other (that I can easily add later - like dynamic menu on a webpage). If you click first option inside the Form connected with the StripMenu you will get some controls that allows you to do something(like inputs on a webpage). If you click the second all these options will disappear and you will get a fresh set of controls where you can do somethingelse (simply another webpage to play with).</p> <p>What is the best way to do it (I find it amazing hard to find out :) ). Only way I figured out (more from experience in js then tutorials) is to use show/hide like in javascript/html.</p> <pre><code>ExamplePanel.Visible = false; ExampleOtherPanel.Visible = true; </code></pre> <p>But this doesn't seem right - I think it would be impossible to manage in bigger program (not only in code, but visual designer too - you can only fit that much Panels inside Form).</p> <p>Any advice? Or at least a link to material where I can find out?</p> <p>EDIT: Finaly I gave up and used multiple Forms as sugested in answer.</p> <pre><code> private void MenuStripExample_Click_1(object sender, EventArgs e) { SomeForm SomeForm = new SomeForm(); this.Hide(); //Hide the main form before showing the secondary SomeForm.ShowDialog(); //Show secondary form, code execution stop until SomeForm is closed //this.Show(); //You may uncomment this if you want to have the previous Form to get back after you close new one } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload