Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Select Case 4

Status
Not open for further replies.

TRHorn

Technical User
Feb 21, 2010
24
US
I can't really remember how to implement a select case.

Here is the deal. I have a User Form that has some option buttons on it. I want a different thing to happen depending on which one is selected. It seems that select case is the best way to implement this but I don't know how to detect which is selected and send the number to the select case loop.

I hope that was clear.
 
>In this case you can replace a set of option buttons

Sure, or with Check boxes, as I hinted.

However, actually, often you can't. Important nuancs and inferencese are lost. The idea that you can go around simply swapping one metaphor for another and they somehow do the same thing is misguided, and the cause of many poorly designed interfaces.

The reason that many of these basic controls exist (and are consistent over different operating systems and different GUIs - Windows, OS X, Gnome, KDE, etc.) is that they serve a very exact (and well understood) purpose. Try and make them serve a different purpose and things go wrong.

>she wants to use option buttons like command buttons

Then use a blinking command button. Goodenss sake. It isn't like there isn't a control that actually does what she wants ...

>when you select the option (none is selected by default, of course) you go straight to the office's menu

Here's a summary of more instruction from the Microsoft Style Guide: do not use option buttons to initiate actions.


> all other options are disabled (grayed out). So, really you do not have any options to choose from, just one. Is that an option?

Technically, this is legitimate
 
Back to your first post Andrzejek

That's simply a way I never would have thought of structuring a Select-Case ... Very Nifty.

worth a star

sam



 
strongm,

I appreciate your explanation on the user interface. I like how you are often able to explain complicated concepts (at least complicated for some of us) in a very simple way. Kudos to you. Speaking of Kudos, do those little candy bars still exist? I don't think I've seen them since I was 12.

-Joshua
Well, You can try banging your head against the wall, but you just end up with lost-time injuries and damaged equipment. [M. Passman]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top