Nov 22nd, 2003, 09:43 AM
#1
Thread Starter
Frenzied Member
creating objects at runtime [resolved]
Ho do I make an object at runtime? Lets say I want a textbox to appear everytime someone clicks on a button, how would I do that?
Last edited by Acidic; Nov 22nd, 2003 at 10:11 AM .
Have I helped you? Please Rate my posts.
Nov 22nd, 2003, 09:49 AM
#2
Fanatic Member
The easiest wat is to create a control array on the form eg: text1(0). You do this by adding a textbox and setting its index.
While the program is running you call :
Next you set the properties of the new control and set its visible property to true.
This way you will be able to reponsd to events of controls loaded dynamically without having to use subclassing.
Nov 22nd, 2003, 09:53 AM
#3
Thread Starter
Frenzied Member
I'm sorry but I'm a slow learner. Could you please walk me through how to do just that?
What I really need is a 20 by 20 grid of frames which are empty. I then need to name them in a way where the bottom left one is 1,1 and the top right one 20,20.
Have I helped you? Please Rate my posts.
Nov 22nd, 2003, 10:08 AM
#4
Fanatic Member
try this
Dear sir
Please find your solution enclosed herewith
Regards
Mike Thomson!!!
Attached Files
Nov 22nd, 2003, 10:11 AM
#5
Thread Starter
Frenzied Member
wow, that was formal, thx anyway.
Regards Sid.
Have I helped you? Please Rate my posts.
Nov 22nd, 2003, 10:18 AM
#6
Fanatic Member
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