Well apparently the text didn't show up in the email but it does on the
forum sight.

Not sure how this will show up but here it is via email.

<s:DataGroup id="denominationsDataGroup">
    <s:layout>
        <s:VerticalLayout gap="5" useVirtualLayout="false" />
    </s:layout>

    <s:itemRenderer>
        <fx:Component>
            <s:ItemRenderer autoDrawBackground="false">
                <fx:Script>
                    <![CDATA[
                        import com.accesso.utils.CurrencyFormatterWrapper
                    ]]>
                </fx:Script>

                <s:HGroup verticalAlign="middle">
                    <s:Label styleName="uiMockuptext"
                        width="100"
                        textAlign="right"
                        text="{ data.name == -1 ? '' :
CurrencyFormatterWrapper.format(data.name) }" />

                    <s:TextInput id="denominationCount"
                        textAlign="center"
                        width="50"
                        change="{ outerDocument.updateTotal(data,
denominationCount.text) }" />

                    <s:Label text=" = " />

                    <s:Label width="100"
                        styleName="uiMockupText"
                        text="{
CurrencyFormatterWrapper.format(data.flex_value) }" />
                </s:HGroup>
            </s:ItemRenderer>
        </fx:Component>
    </s:itemRenderer>
</s:DataGroup>



Kyle McKnight
Senior UI Engineer - Accesso
602.515.1444 <(602)%20515-1444> (M)

On Tue, Jan 31, 2017 at 8:50 AM, kamcknig <kamck...@gmail.com> wrote:

Hey everyone,

I'm using a spark DataGrid that has an inline ItemRenderer which has a
TextInput inside of it. Whenever the data provider for the DataGrid changes
the amount of ItemRenderers change based on the length of the dataProvider
properly, but the TextInput's text doesnt empty back out. Any renderer's
used previously still have their values filled in.

I have set useVirtualLayout to false on the VerticalLayout I've given it.
I've tried adding an initialText property to the data items and then setting
text="{ data.initialText }" and that clears out the field, but then when the
user puts the cursor in the text area and types the first key they press
doesn't seem to be registered, only on the second key does text actually get
entered.

Following is the DataGrid in MXML the denominationCount TextInput is the one
that I would like cleared when the dataProvider is refreshed.





--
View this message in context:
http://apache-flex-users.2333346.n4.nabble.com/TextInput-in-a-DataGrid-tp14588.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Reply via email to