Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

expand to fit not available

Avatar

Level 7

I hope this can get an answer. There are no fewer than 5 other discussions open about this issue that have not gotten answers from 2010 up to January 2014.

What options can disable "Expand to Fit" under the Layout tab for text boxes?

Situation:

  I have a page set to Flowed. Inside that page, I have a subform set to Flowed. Inside that subform, I have a text field that I want to expand, as needed, to allow more than one line.

Options:

  I don't mind having to script the answer, and I don't mind using the check box. The problem is that the checkbox is grayed-out (disabled).

Anyone have an idea about this?

1 Accepted Solution

Avatar

Correct answer by
Level 7

Going to answer my own question here. The problem can be resolved by editing the XML.

In the <field> tag for the text field, you should have a width and a height. The height (what we're actually worried about) can be set by either 'h' or 'minH'. 'h' is for height that is static, and 'minH' is for expandable fields.

For my case, I changed this:

<field name="tfInstructions" w="196.85mm" h="6.35mm">


To this:


<field name="tfInstructions" w="196.85mm" minH="6.35mm">


The checkbox for "Expand to Fit" is still grayed-out, but on my form, it works.

View solution in original post

1 Reply

Avatar

Correct answer by
Level 7

Going to answer my own question here. The problem can be resolved by editing the XML.

In the <field> tag for the text field, you should have a width and a height. The height (what we're actually worried about) can be set by either 'h' or 'minH'. 'h' is for height that is static, and 'minH' is for expandable fields.

For my case, I changed this:

<field name="tfInstructions" w="196.85mm" h="6.35mm">


To this:


<field name="tfInstructions" w="196.85mm" minH="6.35mm">


The checkbox for "Expand to Fit" is still grayed-out, but on my form, it works.