Results 1 to 3 of 3
  1. #1
    Lounger
    Join Date
    Mar 2006
    Posts
    36
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Form fields won't work after insertion in template

    I have created a template which has 2 option buttons. Depending on which option the user chooses, the text for that particular option is pulled from another document. The separate document has form fields for the user to insert some address information, but when the information is pulled into the template, the form fields don't work because they need to be protected. I foolishly thought that if I protected the document, the form fields would carry that over when pulled into the template, so basically, I want to know how I can protect the template after it has been executed, so that the form fields will work and the user can enter their text into those form fields.

    I have attached both the template and the document
    Attached Files Attached Files

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Form fields won't work after insertion in template

    Try this:

    Private Sub cmdOk_Click()
    With ActiveDocument
    .Bookmarks("caseno").Range.Text = txtcaseno.Value
    .Bookmarks("resp").Range.Text = txtcasename.Value
    .Bookmarks("barno").Range.Text = txtmember.Value
    .Protect wdAllowOnlyFormFields
    End With
    Unload Me
    End Sub

  3. #3
    Lounger
    Join Date
    Mar 2006
    Posts
    36
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Form fields won't work after insertion in template

    Thank you. That worked!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •