I have a form where a user can enter a new name for a specific folder. The full folderpath is displayed on the form for informational purpose which leads to a problem.

I don't want my form to expand its width too much just because the path is so long. So I put the path into a read only textbox with a horizontal scrollbar.

Although it works fine and looks acceptable, I was wondering if anyone has a better idea on how to solve this.

New Name Form, No Scroll

New name form, no scroll

New Name Form, Scroll

New name form, scroll

  • As an aside, I wonder how useful the full path really is in this situation. If I'm only changing its name and not its location, it seems like an unnecessary complication. Perhaps showing just the current name is enough?
    – Matt Obee
    Commented May 13, 2014 at 13:07
  • I actually had this idea some time ago. However, the problem is when there are two folders with the same name but in different locations. Adding the full path easily distinguishs these two folders.
    – mariu5
    Commented May 13, 2014 at 13:15
  • 1
    How does the user get to this dialog? Do they have to navigate the folder tree to find the appropriate folder and then click 'rename'?
    – Matt Obee
    Commented May 13, 2014 at 13:22
  • Yeah I forgot to clarify this. Our company has a special folder structure with one directory for each client. These directories follow a certain template and are basically all the same.
    – mariu5
    Commented May 13, 2014 at 13:24
  • I don't think I understand. You already know which folder you're dealing with, right? You popped this dialog from that particular folder, I assume. So I don't need to know the path. I'm with Matt. Commented May 13, 2014 at 13:29

6 Answers 6


There's a number of issues here.

  1. Input controls aren't meant for displaying data, they're meant for, well, input :). When you show a disabled textbox, the user understands that in some cases it can be enabled. You should use a read-only textbox for the folder path.

  2. It would be a good idea to populate the New Name field with the current name, and just name it Folder Name.

  3. Group boxes aren't really used any more, but even regardless of trends - when they're used, it's for grouping controls. A group box that contains a single control is redundant in 99% of the cases, because there's nothing to group.

  4. It's usually a good idea to add a Cancel button if you have a Confirm button. The X at the top right isn't enough.


download bmml source – Wireframes created with Balsamiq Mockups

  • 1
    Ok and Cancel are conceptually Next and Back, so I would place Ok on the right rather than Cancel (Yes, I know Microsoft did it the other way around, but it's still wrong :P)
    – Franchesca
    Commented May 13, 2014 at 13:46
  • 3
    Also, displaying the path in the first field indicates (to me, anyway) that the second field wants a path too. And I don't think you want a full path entered into that field. Commented May 13, 2014 at 14:02
  • +1 and I would like to add that maybe it would be beneficial to use Target folder: C:\text\of\full\path\to\folder followed by New folder name: user-supplied input and then lastly New Target folder: C:\text\of\full\path\to\user-supplied-folder and the New target folder: should update as the user types
    – MonkeyZeus
    Commented May 13, 2014 at 16:19
  • 2
    @PhilPerry The question is about renaming an existing folder, not about moving it around. Commented May 14, 2014 at 4:58
  • 2
    "Input controls aren't meant for displaying data". Windows apps commonly use disabled EDIT controls for displaying data, because you can select and copy the text out of them. You can't do this with a STATIC (label) control. Commented May 14, 2014 at 8:24

I would get rid of scrolling, and truncate the folder path when the text box doesn't have focus, and indicate this with ellipsis (...) at the end.

When the text box has focus, display a multi-line edit box instead of the single line one.

  • 2
    +1, but ellipsis should really be in the middle as the first and last parts of the path are probably most significant. At the front at least one level should be visible and at the end preferably at least two... Commented May 14, 2014 at 10:29
  • @MarjanVenema Good point!
    – Franchesca
    Commented May 14, 2014 at 11:01

I remember there was a function that will create a String like


I think the parameter was length in pixels or even a windows component where the path should fit in. Sorry I don't remember more, but maybe someone else knows what I mean.

The next step would be to make it clickable and show the full name with word wraps. Just imagine the following shortened directory and assume you have documents in every of your projects:


Or show the full path as hint, that's cool too.

And last but not least, you should remove all size constraints from your software, because you can never be sure what kind of system it will be used on. Just think about translations, font-sizes, dpi-sizes, ...

One more argument: Free Will! The user should be able to decide if the path should be shown in 2560x100 window or as 400x400 or whatever. People get larger screens all the time and then having a tiny box not showing the necessary information is just annoying.


What you could do is have it so the partial folder path displays at first so instead of: D:\Folder\Folder\Folder\Folder you could have it as D:...Folder with an option to show the full path if the user really wanted to see it. However, as Matt stated in may be an "unnecessary complication" because they are not changing the location and simply the name. It could work to have an option for the user to see the full path or not maybe a simple check box so that you don't always have that scroll bar there seems to just add nothing to the program. Just an idea, hope it helps.


Give up? Are you certain this a problem you have to solve? (the answer may be yes of course) However, from here it looks like you're using winforms and interacting with a file system.

Why are you prompting your users to do these types of interaction in new bespoke exciting ways when things like the OpenFileDialog Class exists?

  • I'm asking the user to set a new name for a folder in a template directory. There are several other directories which are based on said template and need to be changed as well. So the user types in the new name and my script then applies that new name to those other directories recursivly.
    – mariu5
    Commented May 14, 2014 at 7:07
  • @mariu5, fair enough, depending on your solution there may still be options that allow you to leverage some widgets that enjoy windows localisation and support.
    – Nathan
    Commented May 14, 2014 at 8:05

I'd advise to get rid of the form in the first place. If you follow the principle of changing something where you see it, then the changing should take place in the location where the name is displayed to the user. (S)he navigated down the path somehow, probably the path can be seen there still, and this is the context where the change should happen. Don't take the user out of the current context.

Windows Explorer does this, for example. Just press F2 while the focus is on a filename.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.