|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Creating a Macro in VBA where a Dropdown Box Populates Text Bookmarks below
Hello,
I am trying to create a lab report document for our company that includes our basic tests on my Macbook. Basically, I want our chemists to be able to say that they did: Test A Test B Test C And, depending on the test, the list of equipment used, procedures, results, and photo requirements change based on the bookmark (for example): Test A Bookmark 3A, 3C, 4A, and 5C show up Test B Bookmark 1A, 2C, 3A, and 4C show up Test C Bookmark 1B, 1E, 4A, and 5D show up All the chemists would need to do would be to insert the information/graphs they gathered when testing. I've never used VisualBasic before, and I don't really know how to program this in... and the videos I watch show people using "fn+control+f9" and inserting IF { {REF} } rather than create modules for this... but it doesn't seem work on my Word 2021 version. Please help! I also have the same question posted here: Creating a Dropdown Box that Populates Bookmarks below - Microsoft Community Last edited by roseheller; 02-22-2021 at 03:25 PM. Reason: Cross-Posting Etiquette |
#2
|
||||
|
||||
Cross-posted at: Creating a Dropdown Box that Populates Bookmarks below - Microsoft Community
where I have already given you links to multiple working solutions on this site: • https://www.msofficeforums.com/word/...html#post46429 • https://www.msofficeforums.com/word-...html#post46903 • https://www.msofficeforums.com/word-...tml#post120392 For cross-posting etiquette, please read: Excelguru Help Site - A message to forum cross posters
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#3
|
|||
|
|||
Thank you Macropod. Sorry about the cross-posting etiquette foul on my end. Didn't know that I needed to add that in.
However, the answers you posted don't seem to work on my computer. I have a Windows 10 business computer that I am required to use and the documents you suggested with examples just simply didn't work. I am sure that your solutions worked for other people, but they don't work for me. If you have any other suggestions, I'm willing to try them out. |
#4
|
||||
|
||||
Merely telling usis hardly conducive to solving the problem. Since there are three solutions I've given you links to, tell us what specific problem(s) you encountered with each.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#5
|
|||
|
|||
Well then, in order of the solutions you gave me:
1. "For a demonstration, see: https://www.msofficeforums.com/word/16379-form-auto-fill-based-different-field-value.html#post46429" --> When I downloaded the document, I see the Dept drowpdown: HR/Finance... and I also see that there is "Code" and "Location" just below. However, when I click on HR or Finance, nothing happens beyond my selecting those words. Nothing else pops up. --> I have tried using IF and REF (with the appropriate Form Field CTRL + FN + F9) but they don't seem to work on my version of Word because nothing happens. It just becomes invisible text once I disappear the Form Fields with ALT + FN + F9. 2. "An alternative would be to use Content Controls, plus VBA. For a demonstration, see: https://www.msofficeforums.com/word-vba/16498-multiple-entries-dropdown-lists.html#post46903" --> When I select Smiths Wholesales/Roundhouse Nurseries, nothing happens immediately. However, I did notice just now, when I was clicking on the page to copy the text, that text appears below, but only if I click on the empty "Client Details" form.... or if I click TAB (now that I've looked at solution number 3 in greater detail) --> This seems like the best option for me to use. I'll need to explain it to the company I'm volunteering for, but this might just be what I'll use. 3. "and, for different elements from a selected item to be output to different content controls, see: "https://www.msofficeforums.com/word-vba/16498-multiple-entries-dropdown-lists-5.html#post120392" --> Ah... okay, I realize what the problem was. I used the "TAB" click whilst it was still in the form version and also when it was protected but only at the location of the "IF" and "REF" statement... I tried it whilst "Protection is enabled" and it worked. Please disregard my statement for the 1st solution... this has all been user error on my end. Sorry, I'm really a VBA amateur so this is one heck of a learning curve on my end. Thank you for your patience. Since I need to create large tables, paragraphs, and indents for each dropdown choice (see screenshot for example) which engineers would need to be able to edit/add information to... what do you recommend? |
#6
|
||||
|
||||
You really need to pay attention to the instructions in the links I provided. Both threads say quite clearly that you need to exit the dropdowns for the updates to occur.
As for Quote:
https://www.msofficeforums.com/word-...html#post87989 https://www.msofficeforums.com/word-...html#post38461 https://www.msofficeforums.com/word-...tml#post145675
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
Thread Tools | |
Display Modes | |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Link CC dropdown to dependent dropdown AND text box | trailrunnertcm | Word VBA | 4 | 02-11-2021 08:04 AM |
Selecting Drop-Down Auto-Populates formatted paragraphs of text | jsarchibald | Word VBA | 2 | 01-06-2021 03:47 AM |
Macro to hide/unhide text to call variable bookmarks | Dr. Z | Word VBA | 2 | 05-27-2017 08:20 PM |
Building blocks show correctly in dropdown, but wrong building block populates in doc | wordgirl123 | Word | 0 | 10-03-2013 08:30 AM |
Macro to populate a text form field based on dropdown selection | koloa | Word | 0 | 10-20-2011 11:52 AM |