replicate tools->options menu in visual studio

Posted on 2004-11-04
Last Modified: 2011-09-20
I would like to replicate the tools->options menu found in Visual studio that has a treeview control on the left, and the various fields for each selection on the right. The type of control seems to be more and more popular, replacing the ugly tab control used in lots of products like Microsoft Word and Excel.

That is just a treeview control on the left, correct? And what type of control is used on the right? Is that just a series of panels. And when you click on a node of the treeview, the panel on the right is activated? I'd like to know how this is most easily managed at design time.

Here is a screenshot of the Options menu I am talking about that is used in Visual Studio.

Question by:brokeMyLegBiking
    LVL 19

    Expert Comment

    Say you have 5 Items in the tree view
    For each of them place a panel on the right side and the panel will contain all the controls, make these panels Ivisible initially

    On the event AfterSelect of the Treeview check the text of the Node selected and correspondingly make the Particular Panel visible

    LVL 25

    Expert Comment

    On the left is indeed a standard treeview, Although I wouldn't go for the invisible option, i would build the right side dynamically. Just put one panel on the right side and on the Node selected build the right side.
    LVL 4

    Author Comment

    Does it take up less memory if you build the controls dynamically? Is it slower? How can I get a sense of what the control layout will look like, in advance?

    LVL 25

    Accepted Solution

    Yes, It will make use of the resources more effiently because it will only load the ones that need to be shown. Especially if your treeview has a lot of items.

    If there aren't that many controls to be shown (less than 50) you will not know the difference in fact it will be faster than with the invisible option because there all the controls of all the items in the treeview will have to be loaded.

    About the layout, what I usually do is make a trial version in the designer to get a general feel of what I want it to look like.
    and than translate that in the code, you probably will have to do that only once to get an idea and that create the rest from that. And than just run your program and see how it looks, usually only small adjustment have to made after that.

    LVL 25

    Expert Comment

    With less that 50, I mean less that 50 per item

    Featured Post

    Top 6 Sources for Identifying Threat Actor TTPs

    Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

    Join & Write a Comment

    Article by: jpaulino
    XML Literals are a great way to handle XML files and the community doesn’t use it as much as it should.  An XML Literal is like a String ( Literal, only instead of starting and ending with w…
    Well, all of us have seen the multiple EXCEL.EXE's in task manager that won't die even if you call the .close, .dispose methods. Try this method to kill any excels in memory. You can copy the kill function to create a check function and replace the …
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    728 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

    20 Experts available now in Live!

    Get 1:1 Help Now