![]() |
|
|||||||
|
|
|
Thread Tools | Display Modes |
|
|
|
#1
|
||||
|
||||
|
Use the following Code:
On Error Resume Next
If CheckBox1.Value = True Then
Set RngSrc = DocSrc.Bookmarks("A").Range
Set RngTgt = DocTgt.Bookmarks("A").Range
RngTgt.FormattedText = RngSrc.FormattedText
RngTgt.Bookmarks.Add "A"
Else
Set RngTgt = DocTgt.Bookmarks("A").Range
RngTgt.Text = ""
RngTgt.Bookmarks.Add "A"
End If
__________________
Graham Mayor - MS MVP (Word) (2002-2019) Visit my web site for more programming tips and ready made processes www.gmayor.com |
|
#2
|
|||
|
|||
|
Quote:
I am hoping that if not selected then the bookmark will be deleted. Basically I have a document with lots of bookmarks line after line on an empty page and if i don't check a lot of the bookmarks then there are a whole lot of spaces in the document from where the bookmarks are. I hope that makes sense. |
|
| Tags |
| vba, word-vba |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Userform with Multiple Cascading Drop Down Lists Populated with External Source Data | venganewt | Word VBA | 21 | 05-16-2018 02:05 PM |
| Auto Populating Data with Drop Down Menu | vmangano | Excel | 4 | 12-20-2016 09:03 AM |
UserForm Dropdown List Not Populating
|
highrise955 | Word VBA | 14 | 04-10-2016 12:10 PM |
| Lack of email addresses auto-populating | LarryK | Outlook | 0 | 10-10-2012 08:09 AM |
"Auto-populating" data-worksheet to worksheet.
|
meggenm | Excel | 4 | 02-04-2012 02:04 AM |