Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 200
  • Last Modified:

Word 2010 activation and deactivation of fields

I hope I can explain this one clearly.  Is it possible to have fields that will either become available or not available based on one field being populated? For example, I have a field for a date and if a date is entered into the field I need two other fields to become active and if no date is entered into the date field I need those fields to be unavailable. In other words, they could not be populated. The fields that would become active or not active are comment fields that will be used for additional information.  Is this possible?  Thank you.
0
SAW56
Asked:
SAW56
  • 3
  • 2
1 Solution
 
GrahamSkanRetiredCommented:
You could do that with 'legacy' form fields in a forms-protected document using VBA coding.
0
 
mlmccCommented:
What tool are you trying to do this in?

You have 3 zones that generally aren't related?
Is this a MS Office/Word issue?
A Crystal Reports issue? A Business Objects issue?

mlmcc
0
 
SAW56Author Commented:
mlmcc - I'm not sure what happened but this was a new question and I only selected Microsoft Word and Microsoft Office. Do you think the browser or this site somehow stored information from the question I posted last week (that one had zones Crystal and Business Objects)?
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
GrahamSkanRetiredCommented:
SAW56,
We need to know if the Word form field, VBA solution could be acceptable, because there is likely to be a lot of detail necessary.
0
 
SAW56Author Commented:
GrahamSkan: The VBA solution would be acceptable but could you give me some idea on how to do it? I am far from an expert with VBA so could you send me an example of how to set it up? Thanks.
0
 
GrahamSkanRetiredCommented:
Use the Developer tab o the ribbon.

You need to put 'Legacy' Text input form fields on the document.

You also need to put an exit macro in a module in the document or in its template. You will probably be designing a template here, so the document will be saved as such. Therefore the code will go in the current document.
 
There is some get-you-started advice on editing VBA code at the end of this article:
http://www.experts-exchange.com/Software/Office_Productivity/Office_Suites/MS_Office/Word/A_7236-Macro-code-to-convert-text-to-fields-in-Microsoft-Word.html

After the code is written, right-click on the date field, select 'Properties and then browse for the macro in the Exit macro box. OK the 'Text Form Field Options' dialogue away. Finally, protect the document for Filling in forms.

The exit macro will run when the text cursor leaves the date field.

The uploaded example is in Word 97-2003 format because the 2007/2010 macro-enabled extension is not permitted here.


FieldValidation.dot
0

Featured Post

Receive 1:1 tech help

Solve your biggest tech problems alongside global tech experts with 1:1 help.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now