![]() |
|
#12
|
||||
|
||||
|
Paul
I think the data was supposed to go into the CC immediately below the drop down. In which case, the code should have been Code:
Private Sub Document_ContentControlOnExit(ByVal ContentControl As ContentControl, Cancel As Boolean)
Dim i As Long, StrDetails As String, aCC As ContentControl
With ContentControl
If .Title = "Current Vendor" Then
For i = 1 To .DropdownListEntries.Count
If .DropdownListEntries(i).Text = .Range.Text Then
StrDetails = Replace(.DropdownListEntries(i).Value, "|", Chr(11))
Exit For
End If
Next
For Each aCC In ActiveDocument.SelectContentControlsByTitle("Current Vendor Info")
aCC.Range.Text = StrDetails
Next aCC
End If
End With
End Sub
Once you settle on a method for doing the Vendor info, you will need to address the repeating info so that you don't have to repeat filling out the same info in multiple places such as (Property Name). Greg Maxey has a good tool available to assist with this - see https://gregmaxey.com/word_tip_pages...rol_tools.html
__________________
Andrew Lockton Chrysalis Design, Melbourne Australia |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
Dependent lists using content control
|
SJPG | Word VBA | 4 | 01-05-2018 02:21 AM |
| Macro to save docx to doc that checks compatibility and converts content controls to static content. | staicumihai | Word VBA | 4 | 10-12-2016 08:23 PM |
| Dropdown dependent text | JakeLRL | Word VBA | 7 | 04-07-2016 08:26 AM |
| make text form field active dependent on dropdown | Glenn0004 | Word VBA | 1 | 06-23-2015 06:13 PM |
| Word drop-down content control dependent display issue | vvcat | Word | 6 | 02-03-2015 11:20 PM |