How To Create A Fillable Form With A Submit Button In Excel

preview_player
Показать описание
In this tutorial you will learn how to create a fillable form with a submit button In Excel. This fillable form can be sent out via email. The recipient then fills out the form, saves it and clicks the submit button. The VBA code running in the background opens outlook, attaches the completed form in email and sends it back to the email address specified. Once received, you can open it and in MS Excel and see the answers to the questions.

Please keep in mind this fillable form is only compatible with MS Outlook. It will not with with Gmail, Hotmail, Yahoo or any other services.

This process works best if the user saves the fillable form to their desktop or documents after filling it out. They can then click the submit button and the form will be sent back to you.

Chapters:
00:00 - Intro
00:53 - Completed Form Sample
01:18 - Form Page Layout
01:40 - Form Header and Logo
02:42 - Add and Format Form Fields
03:59 - Drop Down List From Within Form
05:48 - Drop Down List From Database or Table
08:02 - Use VLOOKUP to Auto Populate Fields
09:38 - Fix #NA Error in Excel
11:20 - Copy VLOOKUP to Other Fields to Auto Populate
12:14 - Display Special Instructions Based on Cell Value
14:47 - Insert Check Boxes
16:06 - Formatting The Form in Excel
18:14 - Hide Table and Database Sheets
20:15 - Create and Format the Submit Button
22:44 - Add Visual Basic Code
24:45 - Protect Form in Excel
26:27 - Test Run
28:42 - Wrap Up

Here is the the Visual Basic (VBA) code needed to create the submit form button to submit the form to email. You can also use this VBA code to send the completed form from to multiple recipients. ***Be sure to update the Subject, Body, Email To, Email CC, Email BCC, and additional Text with your information.***

Private Sub CommandButton1_Click()
Dim xOutlookObj As Object
Dim xOutApp As Object
Dim xOutMail As Object
Dim xMailBody As String
On Error Resume Next
Set xOutApp = CreateObject("Outlook.Application")
Set xOutMail = xOutApp.CreateItem(0)
xMailBody = "Type the body or your email message here" & vbNewLine & vbNewLine & _
"Use this if you want a separate line of text" & vbNewLine & _
"Use this if you want another separate line of text"
On Error Resume Next
With xOutMail
.CC = ""
.BCC = ""
.Subject = "Enter the Email Subject Here"
.Body = xMailBody
.Attachments.Add ActiveWorkbook.FullName
.Display 'or use .Send
End With
On Error GoTo 0
Set xOutMail = Nothing
Set xOutApp = Nothing
End Sub

Check out these programs I use for YouTube

Follow me on social media:
Twitter: @melissaecompton
Instagram: @melissaacompton

This description contains affiliate links and I may be paid a small commission should you purchase using these links.

#melissacompton #excel #FillableForm
Рекомендации по теме
Комментарии
Автор

Hi Melissa, this is really helpful! I hope you could also do another video, instead of sending it via email. The information will dump to another sheet on the same file. Thank you!

QuinvieGaming
Автор

Your style is easy to follow. You are a brilliant and a super effective teacher!

PureSearch-bwli
Автор

I truly appreciate your exceptional effort in meticulously addressing nearly every specific requirement for those Excel forms. Thank you for your outstanding work!

nirranjankaayatek
Автор

Really helpful video. Very clear and not too roomy.

DeeInkersole
Автор

I am Boring (normal) but not anymore thanks to your video. Thanks you Melissa. More please ....

rfdave
Автор

Hiii! First of all, super helpful video. <3
What if i want to have the submit button dump all the captured data into a table instead?

RobertRudzek
Автор

Hi Melissa C.,
You're a RockStar! At times(for me), Excel is an alien from another planet, 🤯. Your visual instruction is great! The topics that you cover, examples and tips that you share are perfect; most of all, your voice is not annoying 🙄 its easy listening 🙂. Their are some Excel docs I need to create at work and your video is one of the first videos I viewed👌and will be referring to it ALOT, TY 👏👏🫶

Mbartn
Автор

Thank you so much Melissa! You are an excellent teacher.

sharleejohnstonbrosnan
Автор

Hello, Melissa! So sorry for the confusion. Yes, it was for you!

gayedougherty
Автор

Thank you! I really enjoy your tutorials!

bethlamb
Автор

great video, I used some of the information you shared to create a form in excel, then the user can print it as a pdf so they can digitally sign it. thank you for sharing this.

urdecisionisurs
Автор

Hi Melissa! Very helpful tutorial. Could you also do another one, instead of sending an email, the data on the form is saved to an excel spreadsheet? Or maybe just share the VBA code for it if you dont want to do another tutorial? 😅

marxiusbautista
Автор

I am using a mac and attempted to do this and everything works except the submit button. Would be nice if you showed how to go back into the VB code/macros after it was created in case you need to troubleshoot. I have no idea how to do that or solve why submit won't work. Otherwise, loved this video and I echo everyone's comments that we need the data to write into an excel spreadsheet upon submission.

jenniferbudurka
Автор

Great lesson, Melissa. I appreciate your support.👏🏿

webspierre
Автор

This is awesome! But I am wondering if you can make the submit button populate a table/sheet elsewhere in the workbook instead of send an email.

stems
Автор

I know you might not see this but I was wondering if there was a way where, when I click the submit button, the form could take the entries and populate a running list on another sheet within the document?

braingenius
Автор

Thank you!
It would be great if there was a good solution like this for Excel for Mac.

yesitsme
Автор

This great! Thank-you. If I want to be the one who fills the form and sends it to the same recipient daily, (like an order form) can the “submit” button be made to disappear when the recipient opens it? Hopefully the question makes sense.

chrisstaniland
Автор

Great video/tutorial. Thank you. Is there a way to just send one Worksheet, rather than the whole file?

GlennRichardson
Автор

Awesom! Pls, I wanna know how to add a button that will enable the user to attach a photo from his/her file explorer. E.g. attaching proof of payment or something else. Thank you

shy_boyjosh