Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 05-09-2016, 08:30 PM
gmayor's Avatar
gmayor gmayor is offline Disable email function of command button if all form fields are not completed Windows 10 Disable email function of command button if all form fields are not completed Office 2016
Expert
 
Join Date: Aug 2014
Posts: 4,144
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

The following will reset the fields
Code:
Dim oFF As FormField
    For Each oFF In ActiveDocument.FormFields
        If oFF.Type = wdFieldFormTextInput Then
            oFF.TextInput.Clear
        End If
    Next oFF
    Set oFF = Nothing
You don't need the DIM statement if you are adding it to the end of the original macro as it is already defined.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Disable email function of command button if all form fields are not completed Email from Command Button derajlance Word VBA 6 05-05-2016 07:40 AM
Submit to Email Command Button rob7676 Word VBA 0 08-20-2015 05:05 AM
Disable email function of command button if all form fields are not completed command button that generates a popup for sending email oduntan Word VBA 4 03-21-2013 02:15 PM
Disable email function of command button if all form fields are not completed Command button - save in temp folder and send email with attachment bigbird69 Word VBA 13 11-18-2012 10:06 PM
Disable email function of command button if all form fields are not completed Word VBA: How to create a command button and trigger a function? tinfanide Word VBA 2 12-02-2011 05:51 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 10:46 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft