Close Window   
Free Ebook
Get Your Free Excel
Our Top 15 Excel Tutorials
Instant Access!
Subscribe for Free Excel tips & more!

Saving Data From User Form To Excel Worksheet

Forum Register
Search Excel Forum Posts, Tutorials, Macros, Tips, and More


I am new to this VBA business and I have created a user form using VBA in excel to capture data from users. Now i need to save the data from the text boxes and combo boxes I created to be stored in particular cells on particular worksheets. How can i do this?


View Answers     

Similar Excel Tutorials

Close Excel Workbook using VBA Macros
How to close an Excel workbook using VBA and macros, including how to save the file before you close it or discard ...
Prevent Saving a Workbook under a Different File Name
This Excel macro prevents the user from saving an excel file or workbook under a different file name. The file can ...
Use a Form to Enter Data into a Table in Excel
You can enter data into a table in Excel using a form; here I'll show you how to do that. This is a great feature ...
Print Selected Worksheets in Excel
This free excel macro will print all selected worksheets in Excel. If there are no other worksheets selected the a ...

Helpful Excel Macros

Print Selected Worksheets in Excel
- This free excel macro will print all selected worksheets in Excel. If there are no other worksheets selected the active
Disables the "Save As" Feature in Excel
- This macro will disable the Save As feature in excel. This means that a user will not be able to resave the workbook un
Excel Macro to Save a Specific Worksheet as a New File
- This Excel Macro allows you to save a specific worksheet within the Excel Workbook to its own new file. You will be a
Save the Current Worksheet as a New Excel Workbook File
- This Excel Macro will save the currently visible/active worksheet (the one that you see when you run the macro) to a
Print Preview Display for Specific Worksheets in Excel
- This free Excel macro allows you to display the print preview mode or window in Excel for a specified Excel worksheet.

Similar Topics

c, I have created a user form in Excel using visual basic. I have created a command button that clears the data on the user form. The command button clears the text boxes but not the combo boxes. In VB, the programme that I type in is as follows:

Call UserForm_Initialize
End Sub

How do I get it to clear our the data in the combo boxes?

I have created a user form using Excel and VBA where a user can press a submit button to add data to a spreadsheet from the form. I have figured out a way for the user, once the data has been added to the spreadsheet and the form has been cleared, to reload the data from the spreadsheet back to the form in the textboxes. However, I cannot get it to work with combo boxes. Is there a way that this can be done with combo boxes as well?

Hello All!

Heres the scoop.

I have generated a form to compile a text file from multipe text boxes and combo boxes, the data is stored into several different cells each time the user completes the form and hits the button.

As it stands the user enters the data into the fields of the form, the data is written to cells before exporting to a text file, but i need to make sure only ASCII characters are typed into selective text boxes and other selective text boxes will contain numbers only before the information is saved to the cells.

In addition i will need to add a feature to make sure that duplicate entrys are not saved based on a certain text box.


one of my text boxes is labeled ChannelBox; and i want to ensure that the users do not use the same channel number.
I am assuming that i will need to do a VLookup or something, but was hoping that there could be an easier way to store and validate if the channel number has been used previously.

Looking into the future, i will be looking to make a way to edit the stored data and validate that no duplicate entrys exsist.
Probably save this for another day and after i get the program up and running all the way.

I have attached the file for reference.

Is it possible to insert data into a user form from an Excel worksheet?

What I mean is that i have a user form with a number of text boxes. however, i want the data in these text boxes to come from within a specified cell in an excel worksheet rather than the user inputting the data in the text box. I know this is possible when having combo boxes or drop down boxes but id like to do it with a text box as well.

The reason im doing this is to generate a sort of report of the data in a worksheet. If there is any other way please let me know coz i am new to VBA


Dear Sir and all my friends,
I have a problem of transfering data from a user form to a predefined worksheet whrere the data should get stored serially as per the items selected from the combobox on the user form. I am very new to excel and do not know much about excel vb programming. I have 65 items listed in the combobox and it is the 1st control to be selected on the user form while feeding data. Secondly I need to start with the 4th row in the worksheet to store the data for 1st item in the combo list. It should be such that the 1st item data on the user form will get stored in 4th row, the 2nd item in the 5th row and so on till 65th item. And the rows should be fixed for these items. Means when I feed the data for 1st item it should go to 1st row only. If a sample example(showing four to five data input text boxes with combo box list of 65 items (items like AS001,AS002 AB210....not fixed serially but limited to 65 items) data input with code can be replied, It will be of immense help to me.

Secondly, I want to have a time data to be displayed back on the user form in the same format as displayed in the worksheet. I have three text boxes on the user form that give the input to the predefined worksheet the time value. These are calculated in the sheet and stored in a cell that displays the required time data. That data I want to display back while saving the userform input to the worksheet. Example : On the User form X, Text Box 1, 2, and 3 are fed with time (as text) like 456:25, 25:00, 564:33 etc respectively and even sometimes 00:00. When transfered to worksheet Y, they are conditionally calculated and the result is stored in Cell say F2 for first row data. I have a text box on the user form to display thedata stored in F2 in the same format. The time format of the cell F2 is (37:30:55 pattern) I have tried and the data is getting displayed but in a format like 23.4444444 or when I change the value showing 15.33333333444 etc. So how can it be displayed in the same format as in the F2 cell. Note that Full F2 column will be holding the result when I feed the other rows.

Thanking you



Hi Guys,

I am very new to this forum - and really need some help.

I have created a form in vb in excel. Basically, we wanted to send the form to our services aro9und the country and ask them to enter their details - i.e. name address, service information (I created the form with combo boxes, tick boxes as well as text boxes in order for ppl to fill it in). The idea was supposed to be that once the data was entered the service could email this back to us.

I have managed to create the form and then also have found the code for the service to click submit and email the form back...

PROBLEM = the data doesn't save in the form when it is entered. I think, after doing some research that I haven't told this data to go to the excel spreadsheet behind it. NO ONE seems to be able to help me...

Can someone help? Tell me what I need to do...???? Please I will be so grateful. Please, please please?

Thank you guys in advance for taking the time to read this...


If someone could help me with UserForms I would be greatly appreciative. In my workbook (which will be shared by multiple users) I have a few sheets for each individual user. I have created a user form to allow them to enter in the data more easily, but I am not sure how to copy the data from the form to the sheet. I want the user to have the option of either typing the data into the cells or using the form by clicking on a command button (which is already set up). The form which I created also has some combo boxes because I need the users to select only certain data (from named ranges which are already in the workbook).

Additionally, would I have to create a user form for each user (each sheet)...Ideally, it would be awesome if I could just create one user form and put a link on my "Control Panel" page....then have the userform copy the data based into the appropriate sheet based on username. Therefore, the form would know which sheet to paste the data into...not even sure if this is possible.

If anyone could help me to get this working I would very much appreciate your time.


I have an employee that wants to capture data and keep it in a standard format. So I figured I would create a form in access and let him enter the data that way. He then could run reports and queries on the data.

Here is my current situation. I've built the form and have combo boxes, text boxes and a date selection field. I created a table in which to store all of this data. Can I now tell each combo box, text field which table column to store the data in?? Or did I do this backwards and needed to created the table first and then the form?

Apologies is this is an obvious question with a trivial answer.

Background. I'm putting together a spreadsheet that will be connected to word (via Mail Merge (?) - haven't got that far as yet). The users want the data input to be idiot-proof (yeah, I know). Here's how I'm thinking. Sheet 2 contains columns where each column contains the valid values for each combo box on the user form I'll create. On sheet 1 are the various rows of data that have been created by the user selecting items from the combo boxes in the user form and selecting add (push button).

My thought was to "expect" them to mark a row on sheet 1, run the user form which will automatically populate the combo boxes with the values from the selected row, after which they can select other values instead and change the selected row. All well and good (?).

My problem seems to be that if I have the user form running, I can't select a different row from sheet1 and get its values into the user form. Is this dependent on something like the user form being modal or .... or is this NOT a good design to start with ?

Dear Friends,
First of all thanks for all your cooperation you have extended to me so far. I need a help in editing the input data from a user form through another user form. For example When I feed data through a user form , it get stored in a predefined work sheet in predefined rows. Now I need to edit the Data That I have fed in another user form(say the Editing Form). In the editing form, I want to recall the data by selecting the heads from the combolist on the form so that, as per the combobox selection the respective data row(Cell values) are shown on the form in different text boxes. Now after displaying the data from the work sheet on the user form(Editing Form), I want to replace/correct some or the other value and save it so that it goes and get saved on the work sheet back.
(1) On the form I should have a SELECT Button to select the data as per the combobox selection to get the respective data displayed on the specified text boxes.
(2) After the data is displayed, I should be able to edit the data displayed in the text boxes and When I click another button named SAVE, the data replaces the values in the cells of the worksheet with the new edited values. It should be noted that un-edited values should remain as they were. Only changed cell values should be replaced (Over written)with new values.
(3) I am Attaching a sample copy of the workbook (nm766_WorkBook_2) . Request please workout the code by which I can be able to edit the stored data.

Thanking you .

With regards

Hi all

I have created a user form to create, save, edit and delete records to/from an Excel database. It has 2 combo boxes (combo 1 and combo 2). Combo 2 drop down list is dependent on the selection in combo 1. They both use dynamic named ranges for their lists and allow manual user input as well as selection from the drop down list.

When the form is used to read a record from the database, the 2 combo boxes are populated with the data in the record. I need to set the drop down list in combo 2 based on the value in combo 1 ie - I need to determine if combo 1 value was selected from the drop down list or manual user input. I can't use the index value when the record is first populated, as it it <-1 even if the value was originally selected from the list.

What is the best way to determine if combo 1 value is from the combo list or not?

As I am relatively new to coding, I am hoping for a simple answer



I have created a user form, with text boxes to capture certain information. This data then needs copying & pasting to another sheet with headers that match the captured data. The user form will be used daily so will always need to paste to the next empty row on sheet 1. I would only want data to submit when i hit the control button I have created in bottom right corner of the form.

I have read that you can reference in the properties of the text box to a linked cell but I cannot seem to find this anywhere. Is there another way of doing this using code?

There are also 4 tick boxes to get a yes/no answer. How do i get the relevant tick box to put a yes/no answer in the correct column on sheet 1? ( Columns H & I for reference)

I have attached the sheet for reference.



I have a user form with a few text boxes.

Can someone please give an example of what's the best way for the user forms text boxes hold user inputted values in them and for those values to be referenced by other macros.

I know that once a user form is unloaded, all of the data in it goes away. So I would need a command button in it to simply hide the user form.
Is there a way to prevent a user form from being closed by pressing the x at the top right?

I have many rows for which I intend to create such a user form. And the values from the text boxes will be used as values in other code.

Does anyone know of ways to go about this?

Than you

I am new to UserForms and I am trying to create a user form for data entry. I have created my form with 9 text boxes to enter into. Can you format these text boxes so when data is entered into them it is formatted as accounting? Also how can I get the data from the form to my spreadsheet into the next blank row?


i have a form that i have created which has a number of Text boxes and combo boxes.

a user will fill in the boxes and then manually transfer the information

i need a code or macro that i can assign to a button or cell that will clear / reset these boxes when it is clicked,

any ideas would be great


Before i start and to save you time looking at my profile, i am using excel 2010. So i have one worksheet with loads and loads of Combo boxes (form control) that are linked to a cell on another sheet and that sheet uses the linked cell along with a index and match formula in one to fetch data from a range for my chart. So based on the selection of the combo box option the chart changes.

My question is how do i change the size of the text in the Combo boxes (form control)? Is there any VBA to do this? .Font.Size?

If not i don't mind changing all my boxes to Combo boxes (activeX control), but i do have over 100 so what would be the best and fastest way to change all my current Combo boxes (form control) to Combo boxes (activeX control) whilst keeping everything the same so it all still functions. Maybe some more VBA? Plus i also need to be able to change the size in the new Combo boxes (activeX control) as well so telling me how would be splendid.


HI: I'm a new member to the forum: I am not a programmer and although I can do simple vba programming, I am definitely an amateur.
Here's my problem:
I created an Excel form that contains several combo boxes from the Control Toolbox that display the contents of referenced cells in another sheet of the same workbook that is locked and password protected. The combo boxes are linked to the cells that they cover on the form. Everything was working as expected until our office network changed to Windows XP and changed to Excel 2002. Now, every time I print the form, the combo boxes loose their placement on the form and align on the left side of the form.
The editing function on the combo boxes then ceases to function on the combo boxes that moved.
The printed version is printed correctly on the first time, but repeat prints put the combo boxes in their new postions.

Any suggestions on how to keep the combo boxes in their intended position on the form would be greatly appreciated.

Finally, the former company I worked for liked this form so much that the pop up identifier that I had placed on the form which was password protected was unlocked and my name removed and replaced by the company.) Is there a way to prevent similar event from happening to my work.

I have a user form which consists of a drop box and 3 text boxes.

As a sort of data validation when clicking the OK button on the user form I need the following:

If the user selects an item from the drop box then each of the text boxes must be filled with a value, otherwise a message is prompted when pressing OK and doesnt allow the user to continue.

(The drop boxes and text boxes are within a frame - dont know if that makes a difference)

How can i code this as I'm new to VBA and having trouble doing this?

I did read upon few solutions in this forum but I did not find what I was quite looking for. I have few text boxes and few combo boxes in one of my user forms. I have few text boxes and few combo boxes are set to be Required fields that means a user must enter a value in those fields. Please keep into considerations that a user can click on each fields or simply 'tab; thru them. If a user try to skip to next field then I want excel to show a warning message box prompting user to enter a data since this is a required field. Thank you for looking into it.

I have created an Excel userform with a couple of text boxes. How can I dismiss the user form automatically, say after 15 seconds, after the user inputs the data or after 15 seconds whether or not the user has changed the text boxes.

Is it possible to do this? I have been trying to use Application.OnTime but I can't see how to close the userform after the 15 seconds.

I need the following helps in preparing a user form controlled work book with multiple variables.

(a) I have created a user form with combo boxes and text boxes as inputs written to a defined worksheet in the work book. This is covering aound 25 columns when the data entered to the user form once and covering the defined row as it supposed to be. How the data could be written to another work sheet simultaneously in the same pattern?

(b) Secondly, how a simultaneous calculation (Sum function) can be done on the work sheet for each time data entered (need to add values of five inputs fed from the user form) and written to next coloumn as specified. For example If my data input is 05 different time durations entered as in put from the User form and are written to the specified worksheet in Cells D3 to H3. Now as soon as the data written on the columns, I need to fill the Cell I3 or any other selected cell in the same row automatically with the total sum of the cell values of D3 to H3. Can it be done with the VBA codes?

I have a multiple sheet workbook and on one of the sheets, I enter information on clients from a user form. When I activate the user form, I access the full list of clients already entered thru a combo box, so that if the client I want to enter is not on my existing list, I can fill in all the text boxes on the user form and add it to my list. But if the client already exists, I can see it thru the combo box. In such cases, when I select it, I would like that the information that is already entered on this client appears in their respective text boxes on the user form, so I can modify any of them. MY PROBLEM, or rather MY QUESTION is: how to have the text boxes fill in with the appropriate information when I select a client from the combo box? before I hit the OK button?

Thanks in advance

I have a user form with various text boxes, option buttons, tick boxes and combo boxes.

The form is to be used to raise and update various jobs/faults.

I wish to have one of the tick boxes as an option to close the job down. Can anyone help me with the code that will lock out the form for editing when it is clicked.

Also I dont know where to start with code that will grey out certain areas of the form once a certain value is selected from a combo box.


I'm trying to complete a project for work. I have created a user form with several input boxes. I'd like this data to populate cells in multiple worksheet tabs. For example, my "Add Org" user form has text boxes containing information such as "last name" and "date appointed". After filling in the information on the user form, I'd like to click on a command button labeled "submit" which will then populate the data (alphabetically) from the form into both the "Master" worksheet as well as a particular "Organization" worksheet.

Any suggestions that will help me move this project along?

I've created a form and created several combo boxes that use data from another tab in the workbook. Is there a "drop down" box that will do this, plus allow user to enter their own text?

Also, how can I protect headings but allow users to enter data.