Yahoo Answers is shutting down on 4 May 2021 (Eastern Time) and the Yahoo Answers website is now in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.

AriesJWR asked in Computers & InternetSoftware · 1 decade ago

Help with Microsoft Word Macros/Forms?

I have little to no experience with macros. I have a form I am setting up where I have been able to add text form fields etc... and protect the document so it will tab from one field to the next. What I want to be able to do is if box A is checked and you tab it will skip box B or if text field C is completed text field D + E will be skipped.

Is this possible? If so, how do I do this? (specific instructions helpful!)

Thanks!

2 Answers

Relevance
  • 1 decade ago
    Favourite answer

    You need to write VBA code for it. Also, your word file has to be saved as a "Word Macro-Enabled Document" and not save as a regular Word document.

    What I would do is put a checkbox on the form. Write VBA code to trigger where the focus will then move to if this box is checked. But you need to use the Active X checkbox. It's on the Developer Ribbon so click that. There is a "Controls" group. Click "design mode" and then click the arrow beside the box where it shows a wrench and hammer. Click the check box from active X. Put it on the form. Right click on the checkbox and select properties. Make any adjustements to your checkbox here. Be aware of what the NAME is because you'll need this in the VBA code. You can change the name to anything you want. For my example to you I'm naming it "chkBox1". When finished closed this properties box. Now right click on top of the new checkbox again and select view code. Here is where you write your vba.

    It doesn't have to be anything that elaborate for what you have described here. Let's say that if they select this check box you then want the form to move to a text box called "txtBoxA". So here is the code for your checkbox to do that:

    If chkBox1 = True Then txtBoxA.Select

    That's all there is to it. Now you can add on additional IF, THEN, etc if you need to.

  • Anonymous
    1 decade ago

    You're going to have to learn a little programming, and a little VBA, and write a little code. If that's as far as you want to go with it (and not really learn programming), the Dummies books for VBA are pretty good. (Specific instructions would depend on the exact form, and that would mean that you're hiring a programmer - which wouldn't be cheap.)

Still have questions? Get answers by asking now.