#Copying Controls?
6 messages in this thread
Hello again… I would like to know if there is a way in VB to copy
controls from one form to another.
I have a bunch of controls inside a Frame on one Form. I decided that I'd
like to use them inside a Picture Box instead and am finding it tedious to
reconstruct the entire form all over again.
I thought maybe I could create a new form with the Picture Box and copy all
the original controls to it and then delete the old form with the Frame…
but that does not seem possible.
Any and all help would be appreciated. Thanks!
There is 1 Reply.
Terry,
It's simpler than you think!
1. Click on the form
2. Hold the Ctrl key and, one by one, click on all the controls you want
to copy.
3. Press Shift-Del or Ctrl-Ins (copies all the controls to clipboard)
4. Move to your new form by clicking on it
5. Create a picture control and click on it
6. Press Shift-Ins
Voila!
Mark
There is 1 Reply.
Mark,
How nice. I never thought of using the clipboard for copying controls. Is
that documented. I so, I sure missed it.
George
There is 1 Reply.
George,
I think it's documented. Actually, I found it by accident during beta and
sent in a "kudos to the developers" message cuz I thought it was neat too!
Mark
There is 1 Reply.
Now you tell me!!
There is 1 Reply.
Thanks for the tips! Of course, after I logged off CIS, I discovered how
to copy controls by searching the Help Text! However, I didn't think about
using the Ctrl key to select more than one control. I ended up copying them
all one-by-one! Oh well… learn something every day! Thanks again.