Try this:
1st Type this in the document:
"Version #", CTRL+F9 (to insert a field), "{ DOCVARIABLE VNUM }"
Put his code in a module:
Code:
Sub Increment()
On Error Resume Next
With ActiveDocument
.Variables.Add ("VNUM")
On Error GoTo 0
If IsNumeric(.Variables("VNUM")) = False Then
.Variables("VNUM") = 1
Else
If .Saved = False Then
.Variables("VNUM") = .Variables("VNUM") + 1
Else
MsgBox "No changes!"
End If
End If
.Fields.Update
.Save
.Close
End With
End Sub
Assign this macro to CTRL+M keyboard shortcut.
The Ctrl+W is really necessary? Why not just save and close the document ?
Test before use, backup your files before, use at your own.