In need of some assistance, I am working with a MultiLine asp:Textbox (similar to a standard html textarea) that I would like to have auto-sized to fit its content using only CSS. My goal is to have it display at a specified height in the web browser, with scrolling enabled.
Though I have successfully implemented a print style sheet, I am encountering an issue where text inside the textarea is being cut off when printed due to overflow being hidden.
I attempted to manually set the height of the textarea in the print.css file, but this approach presents problems as the fields are not always required and having a 350px empty box is not ideal, especially since there could be more text than anticipated.
I experimented with:
height: auto;
height: 100%;
In different browsers such as IE and Firefox, but these styles seem to be overridden by the row number specified in the HTML markup for the form. It appears that .NET automatically generates this row count if a height is not specified on the asp:Textbox tag, which only accepts numerical measurements like px or em.
If you have any suggestions or solutions, please share them!