|
|
|
Как создать TextBox in run time? Не получается.
|
|||
|---|---|---|---|
|
#18+
Хочу создать TextBox. Всё делал по хелпу VB5. Но не работает? Почему? Появляется сообщение "Object required" Вот мой код Public Sub Form_Load() Dim Text1 Dim objText As TextBox Set objText = Text1 objText.Text = "HELLO!" End Sub А вот текст из хелпа Бэйсика, статья "Creating Objects" Similarly, you can declare an object variable that can refer to any text box in your application: Dim anyText As TextBox ' Can refer to any text box ' (but only a text box). You can also declare an object variable that can refer to a control of any type: Dim anyControl As Control ' Generic control variable. Notice that you can declare a form variable that refers to a specific form in the application, but you cannot declare a control variable that refers to a particular control. You can declare a control variable that can refer to a specific type of control (such as TextBox or ListBox), but not to one particular control of that type (such as txtEntry or List1). However, you can assign a particular control to a variable of that type. For example, for a form with a list box called lstSample, you could write: Dim objDemo As ListBox Set objDemo = lstSample Кто подскажет? ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 20.08.2007, 13:18 |
|
||
|
Как создать TextBox in run time? Не получается.
|
|||
|---|---|---|---|
|
#18+
... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 20.08.2007, 13:45 |
|
||
|
|

start [/forum/topic.php?fid=60&msg=34738576&tid=2163560]: |
0ms |
get settings: |
4ms |
get forum list: |
12ms |
check forum access: |
2ms |
check topic access: |
2ms |
track hit: |
131ms |
get topic data: |
7ms |
get forum data: |
2ms |
get page messages: |
23ms |
get tp. blocked users: |
1ms |
| others: | 215ms |
| total: | 399ms |

| 0 / 0 |
