|
Tip>Designer |
|
|
Using GhostFill's date selection functionality after assembly |
|
|
Article #: |
0032 |
|
Contributor: |
Gail Moodie |
|
GF version: |
All |
|
Applies to: |
Entering dates in a document that has been assembled |
|
Last updated: |
December 24, 2001 |
Description
Open the GhostFill date selection interface after a fill operation and select a new date to insert into a document.
Explanation
After a document has been filled, it may be necessary to edit the dates that have been entered. A quick and simple way of doing this is to force the GhostFill date selection interface to open and to select a new date.
How to open the GhostFill date selection interface.
Create a macro in the Visual Basic Editor that contains the following code:
Sub InsertDate()
Dim GFCalendar As Calendar
Dim val As String
Set GFCalendar = CreateObject("GFCalendar.Calendar")
val = GFCalendar.Capture("Select a start date", Now())
Selection.InsertAfter (val)
End Sub
If you are likely to use this macro regularly, it is advisable to copy the macro template file into your Word Startup directory and assign a shortcut key to the macro:
Right-click on the toolbar in Word, then click Customize.
In the Custom dialog box, click Keyboard.
The Customize Keyboard dialog box opens. In the Categories box, scroll to Macros. Click Macros.
In the Macros box, click the Macro to which you want to assign a shortcut.
Click in the Press new shortcut key box, then press the combination of keys on the Keyboard, e.g. ALT + D.
Click Assign to assign this combination to your new macro.
Now, after a fill, simply press ALT + D to open the date selection interface and choose a new date.