Getting Radio Buttons to work, that are inserted via AutoText

Joined
Nov 26, 2020
Messages
3
Reaction score
0
I have a template where i need to ask a few questions.
The template only shows 1 question to begin with (in Section 3 of document), with 2 radio buttons for answers (Yes and No).
When selecting either answer, the macro will begin by deleting section 4 (BTW - nothing in Section 4), then it will add a new section 4 and place AutoText into it.
If they choose 'No' , the AutoText loaded is just a paragraph, (no problem here - this works fine)

If they choose 'Yes', I want to load another question with 2 radio buttons (Yes and No). I've saved this second questions and their radio button options as AutoText. The AutoText will load correctly, however when trying to select one of the radio buttons pasted in via the AutoText; it will not link to the code and run the next lot of AutoText (with more questions). It comes through as a picture and not as an ActiveX control as I saved it.
  • The template document has the code saved in "ThisDocument" in VBA
  • The reason I add a blank Section 4 in the template, deleting it and then adding back in to place the AutoText result in there; is so my staff can toggle between their answers. e.g. when they first answer Q1, they may choose No. They may then save the document, come back later and choose Yes. So doing this will delete section 4 with the resulting AutoText, and load the AutoText afresh each time.
When I right click on the radio buttons inserted by AutoText, and 'View Code' - it opens a new blank Private Sub with the exact same name as the code already saved in "ThisDocument". I just cannot understand why it won't point to the correct Radio Button code??

Geez I hope what I've said makes sense!! Sorry if its confusing!
I can send file if it helps (cannot upload as it won't accept .dot format (Yes having to use an 97 MS template too, but working in MS365)
 

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