Create the Data Entry Form using Macros (VBA) in Excel Office 365!
Tags: createthedataentryfo, vbamacros
Published: 2021-01-27 04:03:05

---
title: Create the Data Entry Form using Macros (VBA) in Excel Office 365!
published: true
date: 2021-01-26 12:03:46 UTC
tags: CreatetheDataEntryFo,VBAMacros
canonical_url: https://geekexcel.com/create-the-data-entry-form-using-macros-vba-in-excel-office-365/
---

Sometimes, we may need a data entry form to store huge information in an Excel workbook. You can easily achieve this task with the help of Macros. In this article, we are going to see how to **Create the Data Entry Form using Macros ([VBA](https://geekexcel.com/excel-office-365-vba-overview-definition-and-examples/)) in Excel** Office 365. Let’s get into this article.
## Create Data Entry Form using Macros:

Follow the below steps to insert a data entry form into your worksheet.

- Assuming that, we have a data table with students’ names, class, and marks, we are going to register them in a form.
- The below screenshot shows the table structure with column headers.

![Example table](https://eadn-wc04-371788.nxedge.io/cdn/wp-content/uploads/2021/01/EXCEL_1oGN6bBEtW.png)<figcaption id="caption-attachment-21463">Example table</figcaption>

- On the **Developer Tab, select** the **Visual Basic** option under the **Code** section.

![Select Visual Basic option](https://eadn-wc04-371788.nxedge.io/cdn/wp-content/uploads/2020/09/Select-Visual-Basic-option-5.png)<figcaption id="caption-attachment-14839">Select the Visual Basic option</figcaption>

- You need to activate the sheet where you want to create a data entry form in Excel.
- Now, enter the below code.

VBA code to insert Data Entry form

Sub UseDataEntryForm()

‘Show default data entry form

ActiveSheet.ShowDataForm

End Sub

- You need to **save the code** by selecting it. Then **close** the **window.**

![Save the code](https://eadn-wc04-371788.nxedge.io/cdn/wp-content/uploads/2021/01/EXCEL_WTMPCqFGpv.png)<figcaption id="caption-attachment-21464">Save the code</figcaption>

- You have to open the sheet containing the data. On the **Developer Tab, choose** the **Macros option** in the **Code** section.

![Choose the Macros option](https://eadn-wc04-371788.nxedge.io/cdn/wp-content/uploads/2020/09/Choose-the-Macros-option-3.png)<figcaption id="caption-attachment-14841">Choose the Macros option</figcaption>

- You need to make sure that your macro is selected and **click** the **Run** button.

![Click Run button](https://eadn-wc04-371788.nxedge.io/cdn/wp-content/uploads/2021/01/EXCEL_kYwbEeN1rV.png)<figcaption id="caption-attachment-21465">Click Run button</figcaption>

- At last, you will see the created data entry form as shown in the below image.

![Data Entry Form](https://eadn-wc04-371788.nxedge.io/cdn/wp-content/uploads/2021/01/EXCEL_Sr0zvLbH4q.png)<figcaption id="caption-attachment-21466">Data Entry Form</figcaption>

- You can insert more values in the table using this Sheet1 dialog box.
- Refer to the below image.

![Output](https://eadn-wc04-371788.nxedge.io/cdn/wp-content/uploads/2021/01/EXCEL_soJFXrnM4D.png)<figcaption id="caption-attachment-21467">Output</figcaption>

## Verdict:

In the above article, we have described the steps to **Create the Data Entry Form using Macros ([VBA](https://geekexcel.com/excel-office-365-vba-overview-definition-and-examples/)) in Excel** Office 365. Don’t forget to share your **queries/feedback** in the below comment box. Thanks for visiting **[Geek Excel.](https://geekexcel.com/)** Keep Learning!

### Keep Reading:

- [Excel VBA Date And Time Function in Office 365 ~ Easy Tutorial!!](https://geekexcel.com/excel-vba-date-and-time-function/)
- [How to Add Date in Footer using Macros (VBA) in Excel Office 365?](https://geekexcel.com/how-to-add-date-in-footer-using-macros-vba-in-excel-office-365/)
- [Excel Office 365 VBA Variables & Data Types – A Complete Guide!!](https://geekexcel.com/excel-office-365-vba-variables-data-types-a-complete-guide/)