42

Re the recent question at when are modal dialogs truly necessary?. WHY are modal dialog boxes evil? Is it because people don't read them anyway? Because they are often implemented so poorly? Something else?

Community
  • 1
  • 1
thursdaysgeek
  • 7,696
  • 20
  • 78
  • 115
  • 1
    http://en.wikipedia.org/wiki/Modal_window#Criticisms http://everything2.com/title/Modal+dialog+box Joel and Jeff Atwood both have posts on the subject as well (easily found via google) – Frank Farmer Jan 14 '10 at 04:42
  • 1
    Because between 2008 and 2012 Stack Overflow changed such that this kind of question is "not constructive" because it is based on "best practice" rather than "how to.." .I just got annoyed by a stupid modal dialog on Visual Studio that told me what I needed to do but wouldn't let me do it until it was dismissed by which time of course the instructions were no longer visible. – CashCow Jul 04 '17 at 10:46
  • Microsoft Outlook I think has an evil dialog whereby you can't search your inbox for e-mails that contain the user names you want to add to an e-mail or address book. – CashCow Jul 04 '17 at 10:47
  • @CashCow - hah! That's a really good example of bad design. – thursdaysgeek Jul 05 '17 at 15:25
  • The Wikipedia article has a good summation of the complaints. – Alana Storm Dec 12 '08 at 00:14

10 Answers10

66

About half of the answers so far are addressing the flaws of confirmation dialogs, not of modal dialogs. While the vast majority of confirmation dialogs are modal, this does not mean that the two terms are synonymous.

A modal dialog is one which puts the program into a specific mode and does not allow you to do anything which doesn't correspond to that mode while it is open. In the most common implementation, this means you can't access any other windows.

This is evil.

Consider an address book application. Suppose you have an existing person in the address book and you wish to add their roommate.

  • If the "add person" dialog is non-modal, you can flip back and forth between the old record and the new one copying and pasting your data.
  • If the "add person" dialog is modal, you can't do anything with the old record while the add dialog is open. You can select something to copy before selecting "add", but just one thing. Everything else has to be manually retyped.

On rare occasions, you run into something which truly must be done in one piece without allowing the user to diverge from that task until it is complete. Modal dialogs are appropriate for such cases. But these cases are very rare! Which is basically the point of the other thread referenced by this question.

Dave Sherohman
  • 45,363
  • 14
  • 64
  • 102
  • 1
    Are you saying confirmation dialogs are not evil? – Pyrolistical Dec 12 '08 at 02:40
  • 7
    I am saying that confirmation dialogs and modal dialogs are orthogonal - the evilness of one is unrelated to the evilness of the other. (Since you asked, I would say that confirmation dialogs are merely pointless on their own. They are not evil unless they are also modal.) – Dave Sherohman Dec 12 '08 at 17:09
  • 1
    Agree, most modal dialogs ask you to make a decision based on information that they are effectively preventing you from accessing. The worst is when the modal is raised in an inactive window and you have to spend several moments trying to remember what the process was trying to do. – CurtainDog Jan 14 '10 at 04:49
  • 13
    @CurtainDog: That's not the worst. Worse is when a modal dialog box manages to get stuck behind its parent window. – supercat Sep 05 '10 at 00:02
36

People don't read them, and that's a good thing. You want people to form habits around your UI, but having an important choice in popup is just going to make the user hit OK.

They interrupt the user, they prevent the user from doing other things.

What if you wanted to copy and paste something off the main window? What if you wanted to copy the message in the modal dialog? What if you don't care.

Just compare IE's Find dialog vs Firefox

Compare IE's "Do you want us to remember this password for you?" to Firefox

Pyrolistical
  • 27,624
  • 21
  • 81
  • 106
25

The best UIs are modal. As are the worst.

A modal UI - regardless of whether it is built from dialog boxes, toolbar buttons, or text prompts - is only desirable so long as each mode matches the expectations of the user transitioning to it. When the program transitions into a mode unexpectedly... or the mode requires the user to possess information he does not have readily available... then it will cause the user hardship, either forcing him to revert to a previous mode or guess at the proper action with potentially undesirable results.

A non-modal UI is a complete set of tools. Some are relevant to the job at hand, some are not. A user must have sufficient skill both to choose the correct tools, and to apply them in the correct manner. While a non-modal UI can therefore never be as optimal as a good modal UI (the right tool for the current task already in hand), it can also never be as sub-optimal as a bad modal UI (the wrong tool for the current task slamming into your careless fingers).

Designing a good modal UI can be a fiendishly difficult task for non-trivial applications, especially for general-purpose programs intended to be used by a wide variety of users for an even broader range of purposes. Menu systems and dialog boxes attempt to bridge the gap, allowing small, task-specific modal sections in a larger, non-modal application. Neither one scales particularly well however, and mis-use and overuse have left them with a bad reputation, often seen as the first refuge of the lazy programmer. Dialog boxes in particular are often used more as a means of forcing users into a programmer's (or designer's) idea of how an application should be used, or punting difficult design decisions and tricky error handling at the user, rather than for their namesake goal of communication.

Indeed, the rise of web applications has brought such tendencies to the surface in numerous forums, newsgroups, and Q&A sites such as this one, as programmers accustomed to writing ultra-linear logic which prompts users for input when needed by the program rather than when available to the user... are forced into a system where users can navigate non-linearly, and may well view any attempt to restrict this freedom as a quaint annoyance to be subverted rather than a necessary evil. The plaintive wails of these poor coders echo around the 'Net as their attempts to force this crude modal behavior onto a non-modal system come crashing down around them. For those of us who have long suffered under their cruel "dialogs", it is a lovely tune indeed.

Shog9
  • 156,901
  • 35
  • 231
  • 235
  • I arrived at this question thinking that modal dialog = lazy programmer. I am leaving enlightened. – Jirka Hanika Aug 25 '15 at 09:13
  • But the last paragraph could use a thorough simplification of grammar. Who's the subject of "may well view", I have no idea although I think I somewhat understand your point expressed there, namely that modal dialog = lazy programmer. – Jirka Hanika Aug 25 '15 at 09:17
18

Before you get to read my answer, you must carefully read the following message in it's entirety. All processes, subprocesses, tasks, and threads are suspended indefinitely pending your answer. And, once you completely understand the message, and possibly agree to some legal stuff, and all the implications of all of this, then and only then can you proceed.

Mark Stock
  • 1,713
  • 2
  • 13
  • 23
  • 2
    Hmmm. I don't think anyone is really reading my post. They seem to be skipping over it like they want it to go away or something. Perhaps, there are more important things to do. – Mark Stock Dec 14 '08 at 07:11
7

In a consumer style application, they are more or less useless; users don't read them, learn to dismiss them, and when they DO read them, usually end up being confused. I think a Yes/No/Cancel dialog is downright lazy UI design. The "buttons say what they do" dialog is slightly better, because the user doesn't have to read much.

That being said: In data-critical intranet/"enterprise" applications, they are more or less necessary to confirm destructive actions or to sanity check non-standard workflows that may be allowed but not recommended.

So, I don't think they are conceptually "evil", but more often than not, the result of bad UI design.

davetron5000
  • 24,123
  • 11
  • 70
  • 98
  • Yes. They are tolerable to confirm dangerous choices that you might have done by mistake, or to ask for authorization for such choices. They should only pop when you've done something suspicious. – Loren Pechtel Dec 12 '08 at 03:00
5

They are evil because they violate the basic principle that the user is supposed to be able to direct the software's action. Modal dialogs (the evil form of dialog boxes in general) constrain the user to only one action.

Some answers seem to misapprehend that it's any popup that asks for e.g. user confirmation. This could be accomplished without tieing up the entire app or computer; it's this behavior that people object to.

In some environments, modal dialogs only constrain the user in the context of a single application (or maybe less). Really bad modal dialogs prevent the user from doing anything else in the entire operating system (say, Windows).

dkretz
  • 37,399
  • 13
  • 80
  • 138
4

One of the reasons that I don't like them is because they are showing information in serial(one lot of information at a time) and not parallel(all the information you need to see at once), parallel will allow the user to choose what they want to look at where as in serial you are pretty much forcing them to pick an option.

Plus also the fact that they break a users flow of control(eg steals focus from the object you working on) which I really don't like doing. So in effect from this the user will just hit OK so that they can get back to what they where doing and ignore the information in the dialog box.

Mind you you still need them in some cases.

Nathan W
  • 54,475
  • 27
  • 99
  • 146
3

I don't remember where I saw this first, but a better approach to a modal dialog is often to allow an easy to find and use "undo" capability. Windows Explorer actually does both when you delete a file. It asks for confirmation (modal dialog), then, immediately after deleting the file, the Edit menu has an "Undo Delete" option. just a simple way to access the Recycle Bin, for sure, but in this case, Microsoft really could have just done away with the dialog.

The point being, you can often do without the dialog with a bit of thinking, and perhaps a bit of extra code, but it's just too easy an option for a lazy, or perhaps, more generously, a time-constrained developer.

That said, sometimes you really want a dialog. Think about all of the options on a typical Print dialog. Which printer? All pages, or just a few? How many copies? I don't know how you'd do that without a dialog box...

JeffK
  • 3,019
  • 2
  • 26
  • 29
  • Its easy to get rid of a print dialog. When the user hits print the document view changes to a print preview and a print options panel appears on the side. The user can set the options and hit print and the panel zips away. The user can still edit the document while changing the options. – Pyrolistical Dec 12 '08 at 01:03
  • @Pyrolistical: agreed. The standard print dialog is yet another case of a program asking the user questions when the programmer thinks he needs the information, not necessarily when the user cares to provide it. Given that there's generally some sort of first/default printer, you could just print... – Shog9 Dec 12 '08 at 01:09
  • It does "Just print" if you click on the Print icon in the toolbar – Pyrolistical Dec 12 '08 at 01:13
  • You are describing alternatives to *confirmation* dialogs, not *modal* dialogs. Confirmation dialogs are often, but not always, modal and many modal dialogs are not confirmations. – Dave Sherohman Dec 12 '08 at 01:40
  • You saw it in Alan Cooper's "About Face". – dkretz Dec 12 '08 at 02:02
  • article you mean is here: http://www.alistapart.com/articles/neveruseawarning – FryGuy Dec 12 '08 at 02:36
  • Dave: Right-O. There _is_ a difference I was missing. doofledorfer: It could have been About Face, maybe Jef Raskin's Humane Interface. I think both covered the topic. Pyrolistical: Yep, that would work, but I've got to finish the print feature by Friday... :) – JeffK Dec 12 '08 at 02:58
3

Noboy reads them, and they interrupt the program flow. Often when used as error notification they are the precurrsor to a program failure. By the time the user realizes what is going on, the message is gone and they are left to recall or invent the message as best they can.

user45568
  • 51
  • 2
2

Personally I think it depends entirely on how it is done.

Try copying 10 files where every file exists in the target directory, do it using Windows Explorer.

Is a single modal dialog for each file really the correct answer in such an operation. I know you have "Yes to all", but the entire loop system should've been built differently. It should've gathered all the files that exists into one big list and asked once "What do you want to do with these files", and then let me decide for each file down the list what to do before clicking OK and resuming the operation.

And lots of times dialog boxes just interrupt the normal workflow.

And yes, people don't read dialog boxes. So a golden tip if you must use a dialog box is to reword it.

Instead of "Do you want to delete this row in the database?", try wording it so that you're asking (but this isn't worded right) "Do you want to not delete this row in the database?" This way, if they just hit Yes, which is the typical response from a user who just wants to get on with it, they'll end up doing nothing.

Lasse V. Karlsen
  • 380,855
  • 102
  • 628
  • 825
  • 1
    I wouldn't reverse the question in a modal dialog. Making the user think is actually bad for usability. If users can get exactly what they want done without thinking, you have won. – Pyrolistical Dec 12 '08 at 00:17
  • That will also add another keystroke to the command if people know what the dialog box says and need to delete the row anyway: Del->Enter vs Del->Right/Left Arrow->Enter. – Nathan W Dec 12 '08 at 00:20
  • Not to mention the possibility that the user may want to actually *not* delete the row (if there's no such possibility, then why are you asking for confirmation?), so they click "no"... and it gets deleted. Cue phone call from pissed-off customer. – Dave Sherohman Dec 12 '08 at 01:39
  • What I wouldn't give for a windows explorer file copy dialog that has a "No to All" button! For merging folders, it would be wonderful. – Karl Dec 12 '08 at 01:56
  • 4
    That's rather bad advice. Inverting the sense of the question just makes the problem even worse. It is much better to label the buttons clearly, for example 'Delete row', 'Cancel'. Microsoft have a *lot* to answer to here. – Daniel Cassidy Dec 12 '08 at 02:33
  • People don't deal with backwards questions like that well. – Loren Pechtel Dec 12 '08 at 03:03
  • User struggle to understand basic instructions well let alone reversed ones. – Nathan W Dec 12 '08 at 03:59
  • 1
    It's possible to make 'No' the default button... – bohdan_trotsenko Jun 10 '13 at 10:35