WebNewsReader said:
This one should be easy
How can I create a button control at runtime using one that is already
created and adjust the properties ?
Thanks in advance
So you want a clone of an existing button, then change one or two
things?
Well, just creating a new button is easy:
Dim b as new system.windows.forms.form.Button
I don't think buttons have a clone method, so you could make a
ClonableButton by defining a new class tha inherits Button and
implements ICloneable.
Or just set the properties you want (for quick and dirty solution):
b.property1 = oldButton.property1
b.property2 = oldButton.property2
....