Transfer data from user form to register spreadsheet

N

Neil

Hi All,

I have an excel sheet that is used to collect 'job' inputs, let's call
it the 'userform'.

I also have another spreadsheet that keeps records of all of the
userforms submitted to the work team.



Once the userform is filled out, the work team reviews the inputs then
assigns a job no. from the register.

The job no. is the next available sequential no.



At some stage I need to capture approx. 20 fields containing user input
from the userform and transfer them to the register.

Whilst I could write a very simple macro that has ~ 20 lines that look
like cell a1 on userform goes to cell c3 on the register, I'd like to be
a bit more elegant...



Firstly, all 20 odd inputs on the userform are named ranges, hence are
addressable even if they get moved around (as the form is revised and
improved).



In addition to this the register workbook is likely to transform in time
as well once the preferred configuration is determined.

Here's what I would like to do.

If I have a userform that will be given job no. 57, I'd like to:

Take the value on userform (57) for the variable named 'Contact Address'
and copy the value to the register, specifically at the intersection of
row 57 (job no.) and the column headed with the words 'Contact Address'
(same as the named range for the input).

Repeat this for the other 19 odd userform named ranges...

This way if my register owner moves the columns of data around, my
transfer macro will always place userform data into the correct columns.



How can I achieve this with code?

Any help appreciated...

Cheers, Neil



Excel 2007
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top