views:

365

answers:

3

Hello everyone,

I am writing a very simple WinForms application with few data-entry forms. But before the user gets to these forms, she has to select which action to take (ie which form to open, possibly after entering a search query). As this application is a rewrite of a legacy custom DOS FoxPro app, the user wants the UI to be as similar (read simple) to the old one as possible. (Please note I do not want to discuss how to persuade the customer to migrate to a more modern UI.)

Now, the UI should look like this:

│--------------│
│ Customers >> │ │-----------------│
│ Invoices     │ │ Find customer   │
│ -------------│ │ Create new      │
│ .. etc..     │ │ Delete customer │
│ -------------│ │-----------------│
│ Exit         │
│--------------│

The menu has to be quite large and in the middle of the screen (form). This means that classic MenuStrip is out of the question. Should I create ListBoxes on the fly with the appropriate items? How would you approach this? I already have the navigation structure in stored in objects, I am looking for advice how to present the navigation UI to the user.

Also, in this case keyboard input is essential and more important than mouse interaction.

A: 

I think you can do this with a ToolStrip control. Set Dock=None and LayoutStyle=VerticalStackWithOverflow as a start.

Jamie Ide
+1  A: 

An old project I was on was a conversion of a DOS (Clipper) application to Windows. We decided on something similar to that, with more of a web feel (single-click hyperlinking):

- - - - - - - - - - - - - - - - - - - - - - - 
| Bolded Group Header | Bolded Group Header |
|   Item Link 1       |   Item Link 3       |
|   Item Link 2       |   Item Link 4       |
- - - - - - - - - - - - - - - - - - - - - - -

When double-clicking a group header, all links in that group would be opened at once in the background. Additionally, the context of application (such as a selected customer) was selected via a toolbar, so the current customer details were always displayed.

Technically, we used controls descended from TPanel (this was using the VCL in C++Builder) and client-area labels, but you could easily do something similar in .NET.

Good luck!

EDIT: Just to update since you mentioned keyboard support, Panels get all Windows messages and keystrokes, so responding to them is up to you (we had full keyboard support but we did have to code that ourselves). If you want something that will just work without you having to code anything, I'd go with ListView instead of ListBox controls.

overslacked
+1  A: 

I have been using the Krypton control suite for my windows ui, its really simple to use plus the toolkit is free. It has some great context menu options. There is also the navigation control which provides a stack of menu options.

Rohan West