|
-
Apr 12th, 2000, 02:13 PM
#1
Thread Starter
Addicted Member
Hello!
I'm using an array of Rixhtextboxes, called Text(i), where i = 1,2,3 etc.
When I load the form it only contents one textbox, Text(1). I want the user to be able to (by clicking a button) create a new textbox in the series, Text(2). Then, choose to either create Text(3) or delete Text(2), etc.
Is there a way to do this?
I've thought of creating a lot of textboxes, say Text(1-100), and making them visible or invisible instead of creating, deleting, but it would be rather inconvinent.
So please, if you know how to do it, Help Me!!!
Cheers,
Pentax
Wilhelm Tunemyr,
Swede in London
[email protected]
"Dort, wo man Bücher verbrennt, verbrennt man am Ende auch Menschen"
Heinrich Heine (1797-1856)
Pravda vítezi!
(Truth prevails!)
-
Apr 12th, 2000, 03:34 PM
#2
Conquistador
here you go
Code:
Private Sub Command1_Click()
Dim maxID As Integer
maxID = rtf.Count
Load rtf(maxID)
rtf(maxID).Visible = True
rtf(maxID).Top = rtf(maxID - 1).Top + rtf(maxID - 1).Height
End Sub
did this help?
-
Apr 12th, 2000, 03:46 PM
#3
Fanatic Member
and to unload a control array element
Iain, thats with an i by the way!
-
Apr 16th, 2000, 05:10 AM
#4
Thread Starter
Addicted Member
Well, it helped half way
I can create textboxes allright, but I can't get them visible.
I use them together with a TabStrip, so when you click on a tab I run a For series from i = 1 to [the amount of text-boxes, also the amount of tabs] stating that
If i = TabStrip1.SelectedItem.Index Then
Text(i).Visible = True
Else:
Text(i).Visible = False
End If
It doesn't work! Or rather, it works with Text(1), which hides when I click another tab end reappears when I click tab nr. one, but the new created textboxes doesn't show.
It's not that they have wrong coordinates, I've checked and they are well inside the form.
What can be wrong?
I'm getting desperate...
Pentax
Wilhelm Tunemyr,
Swede in London
[email protected]
"Dort, wo man Bücher verbrennt, verbrennt man am Ende auch Menschen"
Heinrich Heine (1797-1856)
Pravda vítezi!
(Truth prevails!)
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
|