![]() See: Install/Employ VBA Procedures (Macros)įor instructions to employ the VBA code provided above. ORng.Start = Selection.Tables(1).Range.End If MsgBox("Do you want to loop to the first control?", vbQuestion + vbYesNo, "Router") = vbYes Thenįor Each oCell In Selection.Tables(1).Range.Cells (1).Range.Selectĭo Until Selection.Cells(1). > 0 To add a control, click in the document where you want to add it, and then click the control you want to add on the Design tab. In the list of tabs under Customize the Ribbon, select the Developer box and then click OK. The focus does not advance to the next control. View the Developer tab to add or change content controls. Optionally, these content controls can be linked to. Then you can add content controls for elements such as check boxes, text boxes, date pickers, and drop-down lists. To do this, you will start with baseline content in a document, potentially via a form template. Using the tab key in one of these controls enters a physical tab in the control as expected. In Word, you can create a form that others can fill out and save or print. I have unchecked the box 'Highlight the regions I can edit,' and saved the document, but every time it is reopened or sent to a. These open for editing areas are automatically highlighting in yellow. The fields where users can enter data are open for editing. The following example shows three rich text content controls grouped (nested) in a restricted content rich text control container. I have enabled restricted editing in a Word template to be used as a form with fields. Rich text controlsįirst let's look at problems associated with rich text controls. Unfortunately navigating between content controls in documents containing rich text or picture content controls is more problematic. Note: If there are one or more content controls in the document after your assigned "Last" content control then the focus will be set automatically to the content control tagged "First" when you tab out of the "Last" control. Then when you finish in the last content control simply click anywhere in the document and the to exit the content control and the focus will be returned to the content control tagged "First." '"First" = tag property applied to the first control.ĪctiveDocument.SelectContentControlsByTag("First").Item(1).Range.Select ![]() In the Controls group, click the Text Box Content Control icon to insert the first text. Position the cursor a few lines below the dropdown. '"Last" = tag property applied to the last control. Next, let’s add the three controls that will update. Private Sub Document_ContentControlOnExit(ByVal ContentControl As ContentControl, Cancel As Boolean)
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |