is it possible to alter the textarea width and height dynamically on browser enabled forms? - InfoPath Dev
in

InfoPath Dev

is it possible to alter the textarea width and height dynamically on browser enabled forms?

Last post 05-20-2011 06:11 AM by raminou. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 05-20-2011 12:51 AM

    is it possible to alter the textarea width and height dynamically on browser enabled forms?

    Hi,We have a request to change the size (width and heights) of a textarea based on values from a dropdown list. All should be browser enabled. We have tried the following:1.       Alter the view.xsl to add dynamic  width and heights as so:<span><xsl:attribute name=”style”>Width:<value-of select=”my:width”> …This, as expected, worked on infopath, but as soon as we published the form, infopath deleted our modifications on the xsl.2.       We tried the Jquery approach based on this blog http://riteshudupak.blogspot.com/2010/09/add-jquery-to-browser-enabled-infopath.html .  This approach works when loading the form, but anything related to dropdown (where my values are somehow stored) OnChange event do not fire. It seems that the Jquery could only be loaded and executed once at load time.3.       Code approach not supported by browser enabled forms4.       Preserve code block on xsl not supported by browser enabled forms We are as of today desperate as we tried everything we know and nothing seems to work. Our question is: is it possible to alter the textarea width and height dynamically on browser enabled forms. If yes, what would be the approach?   If no, we will have to reengineer our entire solution. Thank you for your helps

     

  • 05-20-2011 05:43 AM In reply to

    Re: is it possible to alter the textarea width and height dynamically on browser enabled forms?

     You can have multiple controls associated with the same node in the schema. Each of these controls can have a different size. Then just hide/show the appropriate control based on the dropdown selection. No code!

    Ernesto Machado
    Qdabra® Software/ InfoPathDev.com
    The InfoPath Experts – Streamline data gathering to turn process into knowledge.™


  • 05-20-2011 06:11 AM In reply to

    Re: is it possible to alter the textarea width and height dynamically on browser enabled forms?

    Thanks for your reply. Actually we've thought about this and we kept it for last resort. This is because the widths and heights of textareas are coming from SharePoint list for maintenance ease.

    Maybe we've forgotten to mention that this a SharePoint list.

    Any other suggestions are welcomed.

     

Page 1 of 1 (3 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.