Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #9  
Old 10-08-2020, 04:11 AM
mbews mbews is offline Can Select Case be used to defined the Value of an item in a drop down list? Windows 10 Can Select Case be used to defined the Value of an item in a drop down list? Office 2019
Novice
Can Select Case be used to defined the Value of an item in a drop down list?
 
Join Date: Oct 2020
Posts: 6
mbews is on a distinguished road
Default

I looked more into the XML side of things and actually managed to implement what I was looking for through that using code I found online. Absolutely delighted!

I have another (hopefully simpler) query now. Further down in the document is a dropdown CC for nearest hospitals and doctors to each site (this is in the sample document). My question concerns the following pieces of code:

Code:
ActiveDocument.ContentControls(10).Range.Text = StrDetails
Code:
ActiveDocument.ContentControls(12).Range.Text = StrDetails
What do I need to change these lines to so they refer to the CC Title or Tag instead of their position in the document? This is vital to me as employees may wish to remove preceding CCs if the data they contain is outdated (until I can update the code) which would cause the Hospital and MIU drop downs to stop working unless the code refers to them in a non-relative manner.

Kind regards,
Michael
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Auto create new worksheet when select option from drop down list JANET JONG Excel Programming 1 08-01-2018 07:13 AM
Select multiple items from a drop down list ConfuddledOne Excel Programming 0 01-30-2017 08:13 PM
Returning a specific value when item is selected from a drop-down list J Press Excel 4 09-10-2012 06:12 AM
Show the first item of a drop-down list instead of a blank Pragabhava Excel 1 12-29-2011 11:48 PM
Can Select Case be used to defined the Value of an item in a drop down list? Automatically select first item in drop-down? flackend Excel 4 08-29-2011 02:07 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 12:43 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