![]() |
#1
|
|||
|
|||
![]()
Hello,
I am new to MS VBA and i have a very special Question. I am trying to hide a bookmarked text with a ContentControlCheckBox. I tried this code: Code:
Private Sub Document_ContentControlBeforeContentUpdate(ByVal ContentControl As ContentControl, Content As String) If ContentControl.Tag = "Checkbox1" Then If Content = "true" Then ActiveDocument.Bookmarks("Test1").Range.Font.Hidden = True If Content = "false" Then ActiveDocument.Bookmarks("Test1").Range.Font.Hidden = False End If End Sub What am i doing wrong? Can somebody help me with this? |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Hide one bookmark when Two checkboxes are checked | AVarg123 | Word VBA | 4 | 04-01-2022 06:21 PM |
REf Fields show Bookmark whole cell when Bookmark is created by code. | pmcpowell | Word VBA | 2 | 11-16-2019 07:05 PM |
Bookmark will not show/hide based on CC Checkbox | lord_kaiser | Word VBA | 1 | 04-17-2018 01:19 AM |
![]() |
lodi123 | Word | 2 | 03-28-2017 11:24 PM |
Find Bookmark, move to bookmark, execute code, repeat | raymm3852 | Word VBA | 10 | 04-15-2016 06:21 PM |