By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,471 Members | 722 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,471 IT Pros & Developers. It's quick & easy.

Clonning Controls.....

Ali Rizwan
100+
P: 927
Hi all,
I want to make an array of controls.
In my case i have an image and a label control i have setted their index to 0. Now i want to create an array of both controls at runtime.

Thanx
>> ALI <<
May 16 '08 #1
Share this Question
Share on Google+
3 Replies


Dököll
Expert 100+
P: 2,364
Hi all,
I want to make an array of controls.
In my case i have an image and a label control i have setted their index to 0. Now i want to create an array of both controls at runtime.

Thanx
>> ALI <<
Hello Ali!

Can you give us a little more background? You can be specific as far as code written on the subject for starters; please also go into what you are trying to achieve. There has to be an idea here for you:-)

In a bit!

Dököll
May 17 '08 #2

QVeen72
Expert 100+
P: 1,445
Hi,

Try This Code:

Expand|Select|Wrap|Line Numbers
  1. Dim i As Integer
  2. For i = 1 To 5
  3.   Load Label1(i)
  4.   With Label1(i)
  5.      .Left = 120
  6.      .Top = i * 300
  7.      .Visible = True
  8.   End With
  9. Next
  10.  
Regards
Veena
May 17 '08 #3

Ali Rizwan
100+
P: 927
Hello Ali!

Can you give us a little more background? You can be specific as far as code written on the subject for starters; please also go into what you are trying to achieve. There has to be an idea here for you:-)

In a bit!

Dököll
Ya ofcourse!
As i say i m building a shell with security support and i was forgot the code that how to clone any control.
Actually i was doing this because on my desktop there must be some icons, and the icons must populate, dynamically that is why i need to make an array of icon instead of creating an array manually of 20,30 or any large number.
So that is why i raise this question but before reading this i was done with my code and i succeed to make an array of controls at runtime. But now i want to make an control for icons. But i was having an other problem that i am using png files for my programe cuz they are better than other all. Control does not support me to set the backgorund completely transperent. It transperents itself but png's shadow also vanished and i cant see the caption of label(caption of icons). Seconf problem in my ocx i m using fade effects on icons. Actually icons are 3-D and are ful of effects. And i m was failed to create such type of effects on the control. For this i need to make a large codings and to call a lot of API's and i was done with this in making of PNG image control. I can't waste my more energy in such case. So i think about the array of 2 controls instead of 1 control.
This programe is maybe the biggest and the best programe of my programming life i m using my whole energy in it. But because of lack of ideas i cant put much attraction than vista's explorer. But its after all better that vista's explore(shell) :). I want to put more effects in it.

Thanx for helping.
>> ALI <<
May 17 '08 #4

Post your reply

Sign in to post your reply or Sign up for a free account.