?
Solved

How do i make a control array?

Posted on 1998-12-31
4
Medium Priority
?
147 Views
Last Modified: 2010-05-03
I am making a computer game and i want to make boxes that i can copy and paste freely that if he is not on he will fall but if he is on he will stay.  I don't need help with the falling part but can someone help me with make the wall.  P.S. I'm very new and I dont know much so if your anserw is not begginer material then explain well
0
Comment
Question by:manly9004
4 Comments
 
LVL 1

Accepted Solution

by:
agrillage earned 300 total points
ID: 1453512
The simplest way to make a control array is to copy and paste a control at design time. You will be prompted to make an array and you answer yes. If you then want to make new instances appear at run time you should use the Load Statement.
0
 
LVL 15

Expert Comment

by:ameba
ID: 1453513
More simple: set index property of the control to 0
0
 

Expert Comment

by:Ajoy
ID: 1453514
to make controls at runtime, have  a  template of the control at design time and set it's index property to zero.u may make this template invisible as per ur requirement.
at run time u can create many instances of this control and assign the left, top,width for this particular instance and place it wherever u want.
Remember u have to set the visibility property to true.

example:
have a textbox on the form
set its index property to 0

in the form load write the following
for i = 1 to 5
   load text1(i)
   text1(i).left = text1(i-1).left
   text1(i).visible = true
next

if u still have problems, feel free to contact me at
Ajoy.Tarafder@in.bosch.com

regards,
ajoy


0
 

Author Comment

by:manly9004
ID: 1453515
This comment didn't make a lot of sense until i used the help file then t helped me alot thanx! I'm forever in your debt(not really).
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction While answering a recent question about filtering a custom class collection, I realized that this could be accomplished with very little code by using the ScriptControl (SC) library.  This article will introduce you to the SC library a…
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses
Course of the Month16 days, 10 hours left to enroll

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question