Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    On validation: Prevent ErrorIcon to shrink width of TextItem

    Hello guys,

    I'm new to SmartGWT.

    When i use SmartGwt's validation mechanism (in SmartGwt 3.0) to check some form TextItem values, the TextItem width will be reduced that the icon fits in if the ErrorIcon visibility is set true (setShowErrorIcon(true)).

    How do I stop auto shrinking the input element?
    For instance, is it possible to insert an extra column for the ErrorIcons to prevent shrinking the input element?

    Would be kind to get some hints.. :)

    Regards, Elmar
    Last edited by esisp; 26 Apr 2012, 23:25.

    #2
    Hi!

    I have the same problem with SmartGWT 2.2. The Comboboxes and DateItem dropdowns shrink after the error icon is displayed. I tried to set the width of the element, the forms second column, but nothing works.
    Also when I tried to make a workaround, as setting the with of the formitems so it won't matter, I can't change the dateitems width. Is there a way to make the dropdons bigger, so they remain readable after the erroricon is displayed?

    Thx, Endre

    Comment


      #3
      The presence of the error icon shouldn't cause problems if the FormItem width is large enough. So the solution is that if you use validation, make the FormItems wide enough to allow for the error icon while still showing the content of the item.

      As far as not being able to set the width of a FormItem, you'll need to post some sample code for us to try to analyze what's going on.

      Comment

      Working...
      X