![]() |
#1
|
|||
|
|||
![]()
Need help with VBA code that will insert a Legacy text field without a bookmark ID and with the Text Format: First Capital. I already have the code to un-protect the form and then turn protection back on after the field has been added so I can add that.
I created a macro (below) but it's not working. It didn't record the steps I clicked to remove the bookmark and change the format to first capital and seems to have added some spaces. Any help would be greatly appreciated. Margaret HTML Code:
Sub test() ' ' test Macro Selection.EndKey Unit:=wdLine Selection.TypeParagraph Selection.FormFields.Add Range:=Selection.Range, Type:= _ wdFieldFormTextInput Selection.Font.Bold = wdToggle Selection.MoveRight Unit:=wdCharacter, Count:=1 Selection.TypeText Text:=":" Selection.Font.Bold = wdToggle Selection.TypeText Text:=" " Selection.FormFields.Add Range:=Selection.Range, Type:= _ wdFieldFormTextInput Selection.HomeKey Unit:=wdLine End Sub |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
sj80 | Word | 1 | 01-26-2016 10:50 PM |
![]() |
Cosmo | Word | 2 | 12-29-2015 11:54 AM |
![]() |
Eduardo Care | Word | 2 | 09-09-2015 03:11 PM |
![]() |
sunrise06 | Word | 9 | 05-02-2015 06:48 PM |
Filling in legacy field causes rest of line to move to next tab stop | rtrdom | Word | 5 | 12-14-2013 05:48 PM |