views:

917

answers:

7

Three buttons, Save, Cancel, Close looks messy, yet after the user has saved the data should they really click a Cancel button?

I need the 'Save' button to leave the form open.

What is best practice?

Thanks

+2  A: 

You should have "OK", "Apply" and "Cancel" buttons. OK button saves the form and closes it. Apply just saves and leaves the form open. And, Cancel just closes the button ignoring all changes. This is how most of the dialogs in Windows do it.

Chris Pietschmann
"OK" is more windows experience-y than "Save"
Grank
Um, yeah, duh, my bad...
Chris Pietschmann
+10  A: 

The standard on Windows is OK and Cancel. The OK button will save and close the screen. The cancel button will close and lose changes. If they want to periodically save changes then add an Apply button. This will save and continue without closing.

Craig
Following the above, 'Close' only makes sense as the only button under a dialog. Use 'Close' instead of OK on a dialog if the contents isn't a message to the user. The important part is that you can 'Close' something and it has no consequence: you are not acknowledging, approving or dismissing anything.
Andre Luus
+2  A: 

Generally, Windows uses the OK / Cancel / Apply system; look at Display Properties, for example. Never a bad idea to go with what's familiar to the user.

McWafflestix
A: 

What happens if the user doesn't want to save the information? Does the form roll back the changes to be displayed again, or does it shut down? If the form needs to close right away, then by all means, dispose of the cancel button. If there is something else that might need to happen, then you might want to keep it around.

Lieutenant Frost
+1  A: 

You could have a Save button and a single Cancel button who's text changes to Close if the data on the form is not "dirty". I've seen this behavior in other programs. That keeps the UI smaller with only 2 buttons.

BoltBait
+1  A: 

The button could be labeled according to the context in which it's displayed.

For example, if the dialog containing the button is intended to perform a specific action, like a "New User Wizard", it should be labeled Cancel .

However, for main application windows or other general-use windows, it should be labeled Close.

UnhipGlint
A: 

Is there a standard convention for this?

From looking at the Display Properties dialog the Apply button is on the right, like this:

[ OK ] [ Cancel ] [ Apply ]

All these buttons are achored to the right. I've seen these buttons in so many different orders that it's hard to know what the standard is (if there is one).

The [ Cancel ] or [ Close ] comment above is logical. Cancel to terminate/roll back a process, or Close to shut the dialog and leave changes applied.

XOS