Button Labels, naming conventions

We recommend following these conventions for labeling buttons:

  • Set the caption (label) using a translatable string from the Strings table.

    This allows for translation to other languages more easily. To indicate that the caption is a translatable string, use a lower-case 's' for the first character. If the string does not already exist in the Strings table, WinStudio prompts you to create it.

  • Designate one character of the caption as the access key.

    Access keys indicate what character the user can press in conjunction with the Alt key as a keyboard shortcut. This access key is typically represented as an underlined character in the user interface.

    In WinStudio, designate the access key by placing an ampersand character (&) immediately before the desired character.

  • If a button opens another form, insert an ellipsis (...) at the end of the label.
  • We recommend that you use names containing only alphanumeric characters, the underscore (_) character, and ellipses (...). Alphanumeric characters include the letters a-z, either upper case or lower case, and the numerals 0-9.  

Sample syntax

Consider this example for naming a button: s&ClickHere...

In the user interface, this button would display like this:

  • The lower-case 's' indicates that this is a translatable string object located in the Strings table.
  • The ampersand (&) indicates that the following letter, 'C', is the access key. In the button caption as it is displayed, the letter 'C' is underlined. This indicates that you can use the keyboard shortcut Alt + C to perform the same function as clicking the button itself.
  • The ellipses (...) indicate that pressing this button opens another form.
Rubriques liées