Clunkie Macro

O

OldSalt

I use the follwoing macro to fill in two fields following
the checking of a box... it works but not smoothly or
consistently... how could I improve it? Is the a way to
write one short macro which handles many checkboxes (and
related text fields)?
 
O

OldSalt

-----Original Message-----
I use the follwoing macro to fill in two fields following
the checking of a box... it works but not smoothly or
consistently... how could I improve it? Is the a way to
write one short macro which handles many checkboxes (and
related text fields)?
.
here is the code:
Sub Checkbox_CSB()
'
' Checkbox_User_Contract_Service_Billing Macro
' Macro created 2/18/2004 by James W. Bruckner
'
If ActiveDocument.FormFields("Check1").CheckBox.Value =
True Then
ActiveDocument.FormFields("CheckText1A").Result =
Application.UserInitials
Else
ActiveDocument.FormFields("CheckText1A").Result = ""

End If

If ActiveDocument.FormFields("Check1").CheckBox.Value =
True Then
ActiveDocument.FormFields("CheckText1B").Result = Date
Else
ActiveDocument.FormFields("CheckText1B").Result = ""

End If
 
C

Charles Kenyon

You can do this using AutoText, giving the AutoText entries and text fields
(or simply bookmarks) names related to the names of bookmarks for your
checkbox fields. What do you mean by "not smoothly or consistently?"
--

Charles Kenyon

See the MVP FAQ: <URL: http://www.mvps.org/word/> which is awesome!
--------- --------- --------- --------- --------- ---------
This message is posted to a newsgroup. Please post replies
and questions to the newsgroup so that others can learn
from my ignorance and your wisdom.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top