Hi Krishna,

Please use this code. It will help you i think.

<?xml version="1.0" encoding="utf-8"?>

<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml";>

<mx:Script>

<![CDATA[

*import* mx.controls.dataGridClasses.DataGridColumn;

*import* mx.collections.ArrayCollection;

[*Bindable*] *private* *var* ac:ArrayCollection = *new* ArrayCollection([

{name:*"Active"*},{name:*"InActive"*}

]);

*private* *function* checkValues(item:Object,col:DataGridColumn):String{

*var* actStr:String = *"1"*;

*var* InActStr:String = *"0"*;

*if*(item.name == *"Active"*)

*return* actStr.toString();

*else*

*return* InActStr.toString();

}

 ]]>

</mx:Script>

<mx:DataGrid id="dg" dataProvider="{ac}" >

<mx:columns>

<mx:DataGridColumn headerText="Converted Value" dataField="name"
labelFunction="checkValues"/>

<mx:DataGridColumn headerText="Original Value" dataField="name" />

</mx:columns>

</mx:DataGrid>

</mx:Application>

Thanks,
Sharan





On Fri, May 28, 2010 at 10:18 AM, Alekhya Krishna <
[email protected]> wrote:

> Hi
> sharanagouda,
>
> Can u Please share the core?
>
> I want datagrid Column name also?
>
>
>
> Thanks
>
>
> On Thu, May 27, 2010 at 3:22 AM, sharanagouda patil <
> [email protected]> wrote:
>
>> Hi,
>>
>> try to use label function to manipulate the data for the column. it will
>> work.
>>
>> if u want i'll share the code for this. Let me know.
>>
>> Thanks,
>> Sharan
>>
>>   On Wed, May 26, 2010 at 1:20 PM, Alekhya Krishna <
>> [email protected]> wrote:
>>
>>>   Hi,
>>>
>>> I have a datagrid, I get the data from the database. In my datagrid have
>>> the columns like
>>>
>>> MyDataGrid
>>>
>>> Title       ,       Status
>>>
>>> Rama              1
>>> krishna            0
>>> Venki              1
>>> yyyy                0
>>>
>>>
>>> This data i will get the data from the database.
>>>
>>>
>>> My Question is i want to display the data instead of Status like 0  -
>>> ---> InActive
>>>
>>> 1 -------> Active
>>>
>>>
>>> I want the MyDataGrid result
>>>
>>> Title       ,       Status
>>>
>>> Rama              Active
>>> krishna            Inactive
>>> Venki              Active
>>> yyyy               Inactive
>>>
>>>
>>> Please help me,
>>>
>>> Thanks
>>>
>>> --
>>>   You received this message because you are subscribed to the Google
>>> Groups "Flex India Community" group.
>>> To post to this group, send email to [email protected].
>>> To unsubscribe from this group, send email to
>>> [email protected]<flex_india%[email protected]>
>>> .
>>> For more options, visit this group at
>>> http://groups.google.com/group/flex_india?hl=en.
>>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Flex India Community" group.
>> To post to this group, send email to [email protected].
>> To unsubscribe from this group, send email to
>> [email protected]<flex_india%[email protected]>
>> .
>> For more options, visit this group at
>> http://groups.google.com/group/flex_india?hl=en.
>>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Flex India Community" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<flex_india%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/flex_india?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups "Flex 
India Community" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/flex_india?hl=en.

Reply via email to