PDA

View Full Version : [SOLVED] Create copy button on userform that autofills information already entered on userform



Ryanchris
10-01-2019, 10:10 PM
On the userform I am creating, the data gathered can be repetitive. For example, I'm asking the user to select certain sizes of parts that they need. I'd like to create a copy button that would allow the user to simply hit the button, and copy the data from certain textboxes to quickly autofill new text boxes. The trick here is that I'm not copying data that has been uploaded to an Excel sheet.

Quick example:
What size pipes do you need? User might fill out 4 text boxes with the following sizes: 3/8, 1/2, 5/8 and 7/8.

The next question would be what size connectors do you need? In most cases, they'll need the same size connectors as pipe. It would be great if they could hit a button that says "Copy from Sizes Above".

I would sure appreciate any help. Is this even possible?

paulked
10-01-2019, 10:34 PM
Hi and welcome to the forum.

Yes! Is the basic answer. Excel lends itself to situations like this. If you give some more details we can help you out (although I'm not around a lot today/tomorrow).

Ryanchris
10-01-2019, 10:56 PM
Hi and welcome to the forum.

Yes! Is the basic answer. Excel lends itself to situations like this. If you give some more details we can help you out (although I'm not around a lot today/tomorrow).

Thanks for the reply! I'm a newbie but learning quickly...If you look at the image that I attached, I think it will help clarify what I am trying to do. Parts 1, 2 and 3 and Fan Coil Sizes for Branch 1 and 2 can be the same for each Port. The ports get labeled A, B, C - all the way to P (16 ports).

I could find a ton of information about how to autofil data that was already in an excel sheet - but nothing like this where I am trying to copy info already on the Userform.

Thanks again!!

paulked
10-01-2019, 11:18 PM
In it's simplest form



Private Sub ComboBox1_Change()
ComboBox2 = ComboBox1
combobox3 = ComboBox1
'etc...
End Sub

Ryanchris
10-01-2019, 11:24 PM
I will certainly give that a try! Thank you so much for your reply. I'll let you know how I get along!

paulked
10-01-2019, 11:32 PM
25196

Without data it's difficult to know exactly what you want, but something like the attached?

You may not be able to post a copy of your workbook because of your post count, but can you put a link to it, ie Dropbox or OneDrive etc?

Ryanchris
10-01-2019, 11:37 PM
I will give this a try and get back to you. Almost 1am here so shutting it down and then diving back in tomorrow. Again - thank you for your help. I really appreciate it.

paulked
10-02-2019, 12:10 PM
This file probably shows it better!

25200

Ryanchris
10-03-2019, 07:13 AM
Thank you so much! That is exactly what I needed. So simple...I was WAY over thinking it! Grateful for your help.

paulked
10-04-2019, 03:36 AM
You're welcome. You can mark this thread 'Solved' by selecting it from 'Thread Tools' drop-down top right of the page.