-
September 15th, 2011, 03:16 PM
#1
Strange problem with dynamically created control
Hi,
I have a strange behavior with a dynamically created TextBox-Control. The control is created in the handler of the Load-event of a dialog-form like this:
txtTitel = New System.Windows.Forms.TextBox
txtTitel.Name = "txtTitel"
txtTitel.BackColor = Color.White
txtTitel.ForeColor = Color.Blue
txtTitel.Location = New System.Drawing.Point(106, 185)
txtTitel.Size = New System.Drawing.Size(406, 20)
txtTitel.TabIndex = 7
txtTitel.Text = ""
Me.Controls.Add(txtTitel)
Now the situation is, that in most cases it works fine. But a few of my customers report that the TextBox not appears on their dialog - it's not there! That's all, nothing more to say.
I appreciate any advice, hints or reports about known pitfalls with dynamically created controls which could explain this (sometimes) strange behavior and how I could fix it (I have to create this control dynamically due to some reasons).
BTW: The program is built with Visual Basic 2005. And the customers with trouble are spread about the OS's (XP, Vista, 7).
Many thanks in advance
Physicus.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|