Controls name

Discussion in 'Questions (Windows Mobile)' started by PepSoft, Dec 13, 2007.

  1. PepSoft

    PepSoft Member Licensed User

    Hello:
    What are the conditions for control names?

    In IDE:
    "TextBox?" or "TextBox#" are not valid names.
    message: "Invalid Control Name"

    but in runtime:
    AddTextBox("Form1","TextBox#",10,10,100,25)

    runs correct.

    There are any problem whith Add Controls whith punctuation symbol in the name?

    PepSoft

    PD: Sorry for my English
     
  2. Erel

    Erel Administrator Staff Member Licensed User

    You should only use letters, numbers and underscore character.
    Controls names (and variables names) must also begin with a letter.
    The AddObjects keywords do not test this. It could cause all kinds of strange errors.
     
  3. PepSoft

    PepSoft Member Licensed User

    Control Names

    Thanks Erel.
    Sorry, Can you give me an example name with underscore character?
     
  4. Erel

    Erel Administrator Staff Member Licensed User

    Sorry. You are right. :signOops:
    Controls do not support underscores.
     
  5. willisgt

    willisgt Active Member Licensed User

    I have dynamically created and referenced controls with a space character as part of the name, without any problems.

    Gary

    :sign0025:
     
Loading...