none
cannot apply bullets to a paragraph containing groupcontentcontrol RRS feed

  • Question

  • I've a paragraph and within this paragraph I have applied groupcontentcontrol on word. Now when I try to put a bullet on this paragraph, nothing happens. Can somebody explain why ? This is irrespective of whether the groupcontentcontrol is applied manually or through VSTO.
    Friday, June 24, 2016 10:09 AM

Answers

  • Hi

    >>So the editing of the word should be restricted, but word is restricting the bulleting of whole paragraph.

     

    In fact, if one word of the paragraph is added to groupcontentcontrol, the whole paragragh should be restricted.

     

    >>One more observation, if I turn on Design mode from Developer tab, then, I'm able to apply bullets to the paragraph.

    Did you try to remove the bullet without Design mode? Apparently, you can't remove it unless turning on Design mode again. As for the reason, there are lots of limitation of content controls. They perform different behavior between design time and run time.

    See "Limitations of Content Controls" in here. In this article,

    Also note that many properties that define the behavior of content controls have no effect at design time. For example, if you set the LockContents property of a content control to True at design time, you can still edit text in the control in the Visual Studio designer. This property only prevents users from editing the control at run time.

    Similarly, the property of groupcontentcontrol only prevents user from editing at run time.

     

    If you want to add the bullet by code, use ActiveDocument.ToggleFormsDesign to trun on design mode, then apply bullet and use ActiveDocument.ToggleFormsDesign again to turn off design mode. Or apply bullets before adding groupcontentcontrol.

    Regards,

    Celeste

    Wednesday, June 29, 2016 1:33 PM
    Moderator

All replies

  • After adding groupcontentcontrol, you can not modify its format.

    A group control defines a protected region of a document that users cannot edit or delete. A group control can contain any document items, such as text, tables, graphics, and other content controls. For more information, see the GroupContentControl type.

    I am quoting from here.



    Friday, June 24, 2016 1:23 PM
    Moderator
  • I understand when group control is applied, it's contents are not editable including formatting. but here in my case, group control is not applied to the whole paragraph, instead only on a word. So the editing of the word should be restricted, but word is restricting the bulleting of whole paragraph.

    One more observation, if I turn on Design mode from Developer tab, then, I'm able to apply bullets to the paragraph.

    Phantom

    Friday, June 24, 2016 7:09 PM
  • Hi

    >>So the editing of the word should be restricted, but word is restricting the bulleting of whole paragraph.

     

    In fact, if one word of the paragraph is added to groupcontentcontrol, the whole paragragh should be restricted.

     

    >>One more observation, if I turn on Design mode from Developer tab, then, I'm able to apply bullets to the paragraph.

    Did you try to remove the bullet without Design mode? Apparently, you can't remove it unless turning on Design mode again. As for the reason, there are lots of limitation of content controls. They perform different behavior between design time and run time.

    See "Limitations of Content Controls" in here. In this article,

    Also note that many properties that define the behavior of content controls have no effect at design time. For example, if you set the LockContents property of a content control to True at design time, you can still edit text in the control in the Visual Studio designer. This property only prevents users from editing the control at run time.

    Similarly, the property of groupcontentcontrol only prevents user from editing at run time.

     

    If you want to add the bullet by code, use ActiveDocument.ToggleFormsDesign to trun on design mode, then apply bullet and use ActiveDocument.ToggleFormsDesign again to turn off design mode. Or apply bullets before adding groupcontentcontrol.

    Regards,

    Celeste

    Wednesday, June 29, 2016 1:33 PM
    Moderator
  • thanks a lot Panchal for clarifying things

    Regards,

    Zain ul Abideen

    Thursday, June 30, 2016 12:07 PM