Using a bitmap object as a item renderer in a datagrid
I have a UIComponent grabbed has a bitmap, and stored in an
array collection.
I want to display a thumbnail in a datagrid, I can make a
itemRenderer for an image with a local or remote file as a source.
But how do I use the bitmap in the array collection in an item
renderer.
Thanks
Dean
Here is an example with a HorizontalList:
<?xml version="1.0" ?>
<!-- itemRenderers\htlist\myComponents\Thumbnail.mxml
-->
<mx:VBox xmlns:mx="
http://www.adobe.com/2006/mxml"
horizontalAlign="center"
verticalGap="0" borderStyle="none" backgroundColor="white"
>
<mx:Image id="image" width="60" height="60"
source="{data.image}"/>
<mx:Label text="{data.name}" width="120"
textAlign="center"/>
<mx:Label text="${data.price}" fontWeight="bold"/>
</mx:VBox>
<?xml version="1.0"?>
<!-- itemRenderers\htlistMainlistThumbnailRenderer.mxml
-->
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml">
<mx:Model id="catalog" source="catalog.xml"/>
<mx:HorizontalList id="myList"
columnWidth="125"
rowHeight="125"
columnCount="4"
dataProvider="{catalog.product}"
itemRenderer="myComponents.Thumbnail"/>
<mx:LinkButton label="Product images courtesy of Lavish"
click="navigateToURL(new URLRequest('
http://www.shoplavish.com'),
'_blank')"/>
</mx:Application>
<?xml version="1.0"?>
<catalog>
<product id="1">
<name>USB Watch</name>
<price>129.99</price>
<image>assets/products/usbwatch.jpg</image>
<thumbnail>assets/products/usbwatch_sm.jpg</thumbnail>
</product>
<product id="2">
<name>007 Digital Camera</name>
<price>99.99</price>
<image>assets/products/007camera.jpg</image>
<thumbnail>assets/products/007camera_sm.jpg</thumbnail>
</product>
<product id="3">
<name>2-Way Radio Watch</name>
<price>49.99</price>
<image>assets/products/radiowatch.jpg</image>
<thumbnail>assets/products/radiowatch_sm.jpg</thumbnail>
</product>
<product id="4">
<name>USB Desk Fan</name>
<price>19.99</price>
<image>assets/products/usbfan.jpg</image>
<thumbnail>assets/products/usbfan_sm.jpg</thumbnail>
</product>
<product id="5">
<name>Caffeinated Soap</name>
<price>19.99</price>
<image>assets/products/soap.jpg</image>
<thumbnail>assets/products/soap_sm.jpg</thumbnail>
</product>
<product id="6">
<name>Desktop Rovers</name>
<price>49.99</price>
<image>assets/products/rover.jpg</image>
<thumbnail>assets/products/rover_sm.jpg</thumbnail>
</product>
</catalog>
Similar Messages
-
Two item renderer for one datagrid column?
hi
i have one doubt
can we use two item renderer for one datagrid column
any possibilities
why i am asking this because
during drag and drop i need one itemrenderer and during application initialization i need another itemrenderer
any possibilities
karthik.kHi,
I think your requirement can be completed by using ViewStack you can pass selected index to it according to requirement.
See:
<itemRenederer ...
<viewstack selectedIndex = 0 ...>
<vBox id="vBox1" >
Your 1st itemrenderer will come here....
</vBox>
<vBox id="vBox2" >
Your 2nd itemrenderer will come here....
</vBox>
</viewStack>
</itemRenederer>
You have to just toggle selectedIndex.
Thanks -
Using multiple data points in an item renderer?
I have a datagrid, bound to data from an XML file. My XML has
multiple items,such as:
<book>
<title></title>
<author></author>
<description></description>
<cover>someimage.jpg</cover>
</book>
I need to display each book as a unit, something like:
[image] Moby Dick
Herman Melville
A long book about a whale.
How would I accomplish this? Obviously, I can easily display
the discrete info in columns, but I'd like to lay it out as one
unit.
Thanks.Use a list control instead of a datagrid. Then use a custom
item renderer based on HBox or VBox depending on your preference
for horizontal or vertical layout... possibly even just a Box
control so you can change it at your whim. -
I'm struggling with how to make a check mark ( image ) show
up or not based on the value of some data in each datagrid line
item. I'm using an item renderer but I'm missing something. Any
help would be greatly appreciated.
thanks,
STeveRThe following is my entire itemrenderer...please excuse any
bad style as this is a WIProgress..
Its probably easier to quote the adobe docs on listdata...If
a component implements the IDropInListItemRenderer interface, you
can use its listData property to obtain information about the data
passed to the component when you use the component in an item
renderer or item editor..I made sure the component implements the
interface as you can see in the code at the top of component. Then
add the couple of required functions regarding listdata, then you
can access the listdata in your own functions in the renderer, like
i do in set data function.
this.BTN_***_mark.label =
value[DataGridListData(listData).dataField];
this line assigns the value from my datagrid to the renderers
button label. (this renderer is a button that the user can press)
so i want the buttons label to show the value coming in from the
datagrid. So listdata is just a way to
explicitly get the column name where the current data is
being sourced from in your datagrid.As the grid is being rendered,
it renders row by row. In each row it goes thru your columns . SO
initially it for row 1 it would begin rendering firstname, surname,
mark, average...etc etc. If i put an alert in on
value[DataGridListData(listData).dataField
I would see these column names popping up as they are getting
rendered in the DGrid.
Hope this helps...
<!-- <?xml version="1.0" encoding="utf-8"?>-->
<mx:VBox xmlns:mx="
http://www.adobe.com/2006/mxml"
creationComplete="init()" width="74" height="30"
horizontalAlign="center" verticalAlign="middle"
implements="mx.core.IFactory,mx.controls.listClasses.IDropInListItemRenderer">
<mx:Metadata>
</mx:Metadata>
<mx:Script>
<![CDATA[
import mx.managers.PopUpManager;
import mx.controls.DataGrid;
import mx.utils.ArrayUtil;
import mx.collections.ArrayCollection;
import mx.collections.IViewCursor;
import mx.controls.Alert;
import mx.events.*;
import mx.controls.dataGridClasses.DataGridListData;
import mx.controls.listClasses.BaseListData;
import mx.controls.dataGridClasses.DataGridColumn;
import mx.containers.TitleWindow;
private var panel:AssessmentMarkPopup = new
AssessmentMarkPopup();
var the_val = 0;
var col_index:int;
private var _listData:BaseListData;
public function get listData() : BaseListData
return _listData;
public function set listData( value:BaseListData ) : void
_listData = value;
private function showLoginForm():void {
var pop:AssessmentMarkPopup =
AssessmentMarkPopup(PopUpManager.createPopUp(this,AssessmentMarkPopup,true));
pop.addEventListener("closepopup",onClose);
pop.TXT_***_mark.text = this.BTN_***_mark.label;
var row:int =
this.parentApplication.DG_class_students.selectedIndex;
pop.student_name =
this.parentApplication.DG_class_students.selectedItem.firstname + "
" + this.parentApplication.DG_class_students.selectedItem.lastname;
private function onClose(e:MyClosePopupEvent):void{
this.BTN_***_mark.label = e.data.mark;
public function newInstance():*
return new MarkEntry();
public override function get data():Object
return super.data;
override public function set data(value:Object):void {
var dg:DataGrid = (listData) ? DataGrid(listData.owner) :
null;
var column:DataGridColumn = (dg) ?
dg.columns[listData.columnIndex] as DataGridColumn : null;
col_index = listData.columnIndex;
var str:String = String(column.dataField);
this.BTN_***_mark.label =
value[DataGridListData(listData).dataField];
]]>
</mx:Script>
<mx:Button click="showLoginForm()" id="BTN_***_mark"
width="52"/>
</mx:VBox> -
Hiding item renders in Group Datagrid Label Rows?
I have an Advanced data grid displaying a grouped collection. I have an item renderer in one column the is a canvas with a button that is bound to the data.
However, buttons are also showing on the header rows, where they are not needed (see below). How do I fix this?I have an Advanced data grid displaying a grouped collection. I have an item renderer in one column the is a canvas with a button that is bound to the data.
However, buttons are also showing on the header rows, where they are not needed (see below). How do I fix this? -
Item Renderer for Advance DataGrid
On AdvancedDataGrid, can we display one of the column as Text and when the user clicks on the text it should turns into a combo box.
When the user clicks on any where else it should turn into text back.
Please help me to implement this.Off the top of my head it's probably something like:
<mx:DataGrid id="dg1" width="100%" height="100%">
<mx:columns>
<mx:DataGridColumn dataField="Example">
<mx:itemEditor>
<mx:Component>
<mx:ComboBox>
<mx:String>1</mx:String>
<mx:String>2</mx:String>
<mx:String>3</mx:String>
</mx:ComboBox>
</mx:Component>
</mx:itemEditor>
</mx:DataGridColumn>
</mx:columns>
</mx:DataGrid>
edit:
Just checked, Subeesh's example: http://blog.flexmonkeypatches.com/2008/02/18/simple-datagrid-combobox-as-item-editor-examp le/ has got a very good example on it. Pretty much exactly what you asked -
Re:Item renderer AS3 for datagrid
I am having a data grid with multiple check boxes for this i am using CheckCellRendererEdit as itemrenderer.When i am making a change in datagrid checkbox its not updating
The problems are
1. when i select a checkbox in second row it gets selected in another row after saving
2.when i choose one checkbox in a row it gets afftected in many row can i get a solution for this Below given is the code i am using
CheckCellRendererEdit.as
package
import mx.controls.*;
import mx.core.*;
import mx.controls.dataGridClasses.DataGridListData;
import flash.events.Event;
import flash.events.MouseEvent;
public class CheckCellRendererEdit extends CheckBox
// Define the constructor and set properties.
public function CheckCellRendererEdit() {
super();
override protected function clickHandler(event:MouseEvent):void
if (!enabled)
{ //DataGrid(this.parentDocument.dg).selectedItem.vdata=CheckBox(event.currentTarget).selec ted;
event.stopImmediatePropagation();
return;
if (toggle)
selected = !selected;Currently i am migrating from flex1.5 to flex2 Just i am using this itemrenderer(checkbox) for DataGrid can i have some ideas for datagrid
The DataGrid i am using is
<mx:DataGrid id="screendg" ">
<mx:columns>
<mx:Array>
<mx:DataGridColumn headerText="mdata" dataField="screenid" editable="false" />
<mx:DataGridColumn headerText="data" dataField="mdata" itemRenderer="CheckCellRendererEdit" />
<mx:DataGridColumn headerText="mdata" dataField="vdata" itemRenderer="CheckCellRendererEdit" />
<mx:DataGridColumn headerText="cdata" dataField="cdata" itemRenderer="CheckCellRendererEdit" />
<mx:DataGridColumn headerText="vdata" dataField="udata" itemRenderer="CheckCellRendererEdit" />
</mx:Array>
</mx:columns>
</mx:DataGrid>
When i am selecting a checkbox in data grid the grid value is not getting changed -
Datagrid Drop Down Item renderer Scroll Problem
Hi,
I am having a problem with an drop down item renderer on a Datagrid. When ever the datagrid is displayed and the cell is clicked on i want this to display a drop down list of objects. I can get the drop down to appear with the list of objects. H
owever the scrollbar does not work on this item to allow the user to scroll through all the objects. If you use the mouse wheel you can scroll down through them all but not when you try and click on the scroll bar to drag down. Below is the code used. Any advice why this might be happening??
<mx:DataGridColumn headerText="Widget"
dataField="WidgetName"
editable="true" headerWordWrap="false" textAlign="center" width="100"
editorDataField="Widget">
<mx:itemEditor>
<fx:Component>
<s:MXDataGridItemRenderer focusEnabled="true" height="22" >
<fx:Script>
<![CDATA[
import mx.events.FlexEvent;
import spark.events.IndexChangeEvent;
private var selectedWidget:Widget = null;
public function get ccyPair():String {
return ddlCcyPairs.selectedItem.Widget;
override protected function commitProperties():void {
super.commitProperties();
trace("Commit .......");
protected function ddlCcyPairs_changeHandler(event:IndexChangeEvent):void {
for each(var ccyP:CurrencyPair in ddlCcyPairs.dataProvider) {
if (ccyP.ccyPair == ddlCcyPairs.selectedItem.ccyPair) {
selectedWidget = ccyP;
ddlCcyPairs.selectedItem = selectedWidget;
protected function ddlCcyPairs_creationCompleteHandler(event:FlexEvent):void {
for each(var ccyP:CurrencyPair in ddlCcyPairs.dataProvider) {
if (ccyP.ccyPair == data.ccyPairName) {
selectedWidget = ccyP;
ddlCcyPairs.selectedItem = selectedWidget;
]]>
</fx:Script>
<s:DropDownList id="ddlWidgets" width="100%"
dataProvider="{parentApplication.Widgets}"
labelField="name"
selectedItem="selectedWidget"
creationComplete="ddlWidgets_creationCompleteHandler(event)"
change="ddlWidgets_changeHandler(event)"/>
</s:MXDataGridItemRenderer>
</fx:Component>
</mx:itemEditor>
</mx:DataGridColumn>Hi, Post a test code.... It will be a lot easier to help you Mich
-
Display item renderer in only some rows of a datagrid
I need to display a combobox item renderer in my datagrid
only in the first of every 5 rows. With the remaining 4 rows in
this particular column empty. Then the pattern will repeat again.
This is how I am currently creating the columns however with
this approach the combobox itemrenderer is appearing in all rows
<mx:columns>
<mx:DataGridColumn headerText="No."
dataField="assCriteriaNum" width="60" />
<mx:DataGridColumn headerText="Assessment Criteria"
dataField="assCriteria" width="210"/>
<mx:DataGridColumn headerText="Mark Range"
dataField="markRange" width="50" />
<mx:DataGridColumn headerText="Mark" dataField="mark"
width="70" >
<mx:itemRenderer>
<mx:Component>
<mx:ComboBox>
<mx:dataProvider>
<mx:ArrayCollection>
<mx:String>0</mx:String>
<mx:String>1</mx:String>
<mx:String>2</mx:String>
<mx:String>3</mx:String>
<mx:String>4</mx:String>
<mx:String>5</mx:String>
<mx:String>6</mx:String>
<mx:String>7</mx:String>
<mx:String>8</mx:String>
<mx:String>9</mx:String>
<mx:String>10</mx:String>
</mx:ArrayCollection>
</mx:dataProvider>
</mx:ComboBox>
</mx:Component>
</mx:itemRenderer>
</mx:DataGridColumn>
</mx:columns>Here is my data provider hard coded
<mx:dataProvider>
<mx:ArrayCollection>
<mx:Array>
<mx:Object assCriteria="A01 Manage." />
<mx:Object assCriteriaNum="1" assCriteria="Brief project
plan, with little evidence of monitoring progress of project work
against the project plan." markRange="(1-3)" />
<mx:Object assCriteriaNum="2" assCriteria="Limited
identification of the topic to be investigated/ researched and
limited evidence of appropriate aims and objectives, and proposed
project title." markRange="(1-3)" />
<mx:Object assCriteriaNum="3" assCriteria="Project plan,
with some evidence of monitoring progress of project work against
the project plan." markRange="(4-6)" />
<mx:Object assCriteriaNum="4" assCriteria="Some
identification of the topic to be investigated/ researched and some
evidence of appropriate aims complete the work and objectives, and
proposed project title." markRange="(4-6)" />
<mx:Object assCriteriaNum="5" assCriteria="Detailed
project plan, with clear evidence of monitoring progress of project
work against the project plan." markRange="(7-10)" />
<mx:Object assCriteriaNum="6" assCriteria="Clear
identification of the topic to be investigated/ researched and
clear evidence of appropriate aims identify the topic and
objectives, and proposed project title." markRange="(7-10)" />
<mx:Object assCriteriaNum="7" assCriteria="No relevant
response." markRange="(0)" />
<mx:Object assCriteria="A02 Use resources/research."
/>
<mx:Object assCriteriaNum="8" assCriteria="Little or no
analysis and application of the research, with few links made to
appropriate theories and concepts." markRange="(1-5)" />
<mx:Object assCriteriaNum="9" assCriteria="Evidence of
limited research involving limited selection and evaluation of
sources." markRange="(1-5)" />
<mx:Object assCriteriaNum="10" assCriteria="Some analysis
and application of the research, with links made to appropriate
theories and concepts." markRange="(4-6)" />
<mx:Object assCriteriaNum="11" assCriteria="Evidence of
some research involving the selection analyse data and evaluation
of a range of relevant sources." markRange="(4-6)" />
<mx:Object assCriteriaNum="12" assCriteria="Critical
analysis and application of the research, with obtain and select
clear links made to appropriate theories and information from a
concepts. variety of sources." markRange="(7-10)" />
<mx:Object assCriteriaNum="13" assCriteria="Evidence of
detailed research involving the selection and evaluation of a wide
range of relevant sources." markRange="(7-10)" />
<mx:Object assCriteriaNum="14" assCriteria="No relevant
response." markRange="(0)" />
</mx:Array>
</mx:ArrayCollection>
</mx:dataProvider> -
Strange Problem with datagrid item renderer in flash palyer 10
Hi All
In Flash player 10 when i use a text input as a item renderer in grid with a custom textinput skin , it does not show us the text , where as in flash player 11 it shows us. is there any work around for it or it's a bug.
Plz help me on this.The url works for me. Please verify that you entered it correctly. There are other sites that will verify your player version. Search for them, pick one and report the results.
Before you file a bug, it is probably best to do some investigation first to make sure it isn’t a known issue or an issue in your code. -
Hi,
I have a comboBox as item renderer in my datagrid (comboBox item renderer code bellow).
1. How can I remove the first blank item? My comboBox arrayCollection doesn't have 0 item.
2. If I come back to the cell that it was already selected with a value from my comboBox, how can I set the selected item of my comboBox to be the same as the previus value? If I leave the comboBox without selection it will be blank as the 0 element.
Please help.
Thanks
Johnny
<?xml version="1.0" encoding="utf-8"?>
<mx:ComboBox xmlns:mx="http://www.adobe.com/2006/mxml"
labelField="label" dataProvider="{acCombo}" rowCount="20"
change="onSelectionChange(event)" creationComplete="init()">
<mx:Script>
<![CDATA[
import mx.collections.ArrayCollection;
import mx.controls.dataGridClasses.DataGridListData;
import mx.events.ListEvent;
import mx.rpc.events.ResultEvent;
[Bindable]private var acCombo:ArrayCollection = new ArrayCollection ([{id:1, label:"Item 01"},{id:2, label:"Item 02"},{id:3, label:"Item 03"},
{id:4, label:"Item 04"},{id:5, label:"Item 05"}]);
private var _ownerData:Object;
public function init():void
//init code
override public function set data(value:Object):void
if (value){
_ownerData = value as Object;
var col:DataGridListData = DataGridListData(listData);
var item:Object = new Object;
var clabel:String = value[col.dataField];
var cid:int = value.id;
item.label = clabel;
item.id = cid;
selectedItem = item;
override public function get data():Object
return _ownerData;
override public function setFocus():void
super.setFocus();
open();
private function onSelectionChange(e:ListEvent):void
if(selectedItem && _ownerData){
var col:DataGridListData = DataGridListData(listData);
var clabel:String = selectedItem.label;
var cid:int = selectedItem.id;
_ownerData[col.dataField] = clabel;
_ownerData[id] = cid;
]]>
</mx:Script>
</mx:ComboBox>Hi,
I created a sample, maybe someone can see the issue for me
Thanks!
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical" viewSourceURL="srcview/index.html"
creationComplete="init()">
<mx:Script>
<![CDATA[
import mx.events.CollectionEvent;
import mx.events.DataGridEvent;
import com.myItemEditor;
import mx.collections.ArrayCollection;
[Bindable] private var acExecution:ArrayCollection = new ArrayCollection([
{Territory:"Arizona", Territory_Rep:"Barbara Jennings", ITEM_ID:1, ITEM_NAME:"Item 01"},
{Territory:"Central California", Territory_Rep:"Joe Smith", ITEM_ID:2, ITEM_NAME:"Item 02"},
{Territory:"Nevada", Territory_Rep:"Bethany Pittman", ITEM_ID:2, ITEM_NAME:"Item 02"},
{Territory:"Northern California", Territory_Rep:"T.R. Smith", ITEM_ID:1, ITEM_NAME:"Item 01"},
{Territory:"Southern California", Territory_Rep:"Jane Grove", ITEM_ID:3, ITEM_NAME:"Item 03"}
private function init():void
private function onItemEditEnd(e:DataGridEvent):void
var cEditor:myItemEditor = dgCustomEditor.itemEditorInstance as myItemEditor;
var item:Object = cEditor.selectedItem;
acExecution.refresh();
]]>
</mx:Script>
<mx:DataGrid id="dgCustomEditor" dataProvider="{acExecution}" height="160"
editable="true" itemEditEnd="onItemEditEnd(event)">
<mx:columns>
<mx:DataGridColumn headerText="Territory" dataField="Territory" width="60"
editable="false"/>
<mx:DataGridColumn headerText="Territory Rep" dataField="Territory_Rep" width="60"
editable="false"/>
<mx:DataGridColumn headerText="Item ID" dataField="ITEM_ID" width="60"
editable="false"/>
<mx:DataGridColumn headerText="Item Name" dataField="ITEM_NAME" width="160" itemEditor="com.myItemEditor" />
</mx:columns>
</mx:DataGrid>
</mx:Application>
Item Editor component
<?xml version="1.0" encoding="utf-8"?>
<mx:ComboBox xmlns:mx="http://www.adobe.com/2006/mxml"
labelField="LABEL" dataProvider="{acCombo}" rowCount="20"
change="onSelectionChange(event)" creationComplete="init()">
<mx:Script>
<![CDATA[
import mx.events.ListEvent;
import mx.controls.dataGridClasses.DataGridListData;
import mx.rpc.events.ResultEvent;
import mx.collections.ArrayCollection;
[Bindable]private var acCombo:ArrayCollection = new ArrayCollection ([{ID:1, LABEL:"Item 01"},{ID:2, LABEL:"Item 02"},{ID:3, LABEL:"Item 03"},
{ID:4, LABEL:"Item 04"},{ID:5, LABEL:"Item 05"}]);
private var _ownerData:Object;
private function init():void
//init code
override public function set data(value:Object):void
if (value){
_ownerData = value as Object;
var col:DataGridListData = DataGridListData(listData);
var item:Object = new Object;
var clabel:String = value[col.dataField];
var cid:int = value["ITEM_ID"];
item.LABEL = clabel;
item.ID = cid;
selectedItem = item;
override public function get data():Object
return _ownerData;
override public function setFocus():void
super.setFocus();
open();
private function onSelectionChange(e:ListEvent):void
if(selectedItem && _ownerData){
var col:DataGridListData = DataGridListData(listData);
var clabel:String = selectedItem.LABEL;
var cid:int = selectedItem.ID;
_ownerData[col.dataField] = clabel;
_ownerData["ITEM_ID"] = cid;
]]>
</mx:Script>
</mx:ComboBox> -
Item renderer for specific rows
I need to have a checkbox item renderer for a spark datagrid column. I am using the following to get an item renderer into column:
var checkBoxRenderer:ClassFactory = new ClassFactory(GridCheckBoxItemRenderer);
column.itemRenderer = checkBoxRenderer;
My question is if I need to show a checkbox for specific rows can I do that without going into GridCheckBoxItemRenderer's source code?
ThanksHi Zolotoj ,
Please go through following links :
http://stackoverflow.com/questions/1952940/show-itemrenderer-in-specific-datagrid-rows-oth ers-empty
http://www.flexer.info/2009/01/09/different-rows-in-datagrid-programmatically-added-itemre nderers-classfactory-and-ifactory/
It will provide you some idea to how to proceed further for this problem.
Thanks and Regards,
Vibhuti Gosavi | [email protected] | www.infocepts.com -
Item renderer on DataGrid (not DataGridColumn)
It seems that all the published examples of using an item renderer on a DataGrid use the itemRenderer property of DataGridColumn.
I don't think I can do this because my columns are created at run time, depending on the contents of the data provider.
I have therefore tried to assign my item renderer (a subclass of Canvas) directly to the DataGrid.
1. This works in MXML when the renderer is inline.
2. It sees to work when the renderer is an Actionscript class assigned to the DataGrid's itemRenderer property.
3. It does NOT work when the renderer is Flex component assigned to the DataGrid's itemRenderer property. This compiler error is reported: Initializer for 'itemRenderer': cannot parse value of type mx.core.IFactory from text 'comp:CellRenderer'.
I prefer to use the last method. Is there a way to fix this error?
If not, is it possible to attach the item renderer to each DataGridColumn as it is created? DataGrid does not seem to have a suitable event that reports when a column is created.
Aplogies if this is elementary stuff. I am a real Flex newbie. I am using Flex Builder 3.0
Andy KirkhamA code example would be helpful here, but from your error message it
looks like you may be doing the following
<mx:DataGrid itemRenderer="comp:CellRenderer"/>
Instead of this, you need to use the fully qualified class name of
CellRenderer, eg.
com.renderers.CellRenderer
Look at the definition of 'comp' towards the top of your MXML file, it
will be something like:
xmlns:comp="blah.blah.blah.*"
Your itemRenderer property should then be set to:
blah.blah.blah.CellRenderer -
Datagrid item renderer destroys on mouse over
Hi,
I used Flex 3.5 datagrid. I used item renderes in my datagrid. and i set 'rendererIsEditor = true'.
Everything is very smooth and good. But somtimes my datagrid acting badly. When i put cursor on itemRenderer, It open-up for
editing. When i move mouse, item renderer destroyed.
Once it happens it is the default behaviour of my datagrid. No editing can be performed.
But i can not reproduce it always. sometimes it a happens.
please help me. anybody know about this?Simplify your test case. Try using a simple TextInput as the renderer and
see if you have the same problem. -
Drag and Drop in Item Renderer
I created an item renderer for use in a TileList. This item
renderer shows a thumbnail, name, and a few buttons. I want to
enable drag but only for the image. I know it is easy to enable
drag for Tile List items as a whole, but how do I do that for just
part of an item, which was rendered using my custom item renderer?
Thanks for any help!Have you tried to turn off drag for TileList and enable it
only for the thumbnail? It should work.
ATTA
Maybe you are looking for
-
EEWB - Add fileds in business transaction item
Hi all, I have added fields in EEWB for the business object SERVICE_CONTRACT and Extension Type PRODUCT_I. It is generated successfully in EEWB, but it does not appear in CRMD_ORDER item tabs. I noticed that the screen is created in EEWB, where as ot
-
How to create custom class for Swing compnents
import java.awt.Color; import java.awt.Font; import javax.swing.JLabel; import javax.swing.*; public class SampleJFrame extends JFrame { public static void main(String[] args) { SampleJFrame frame = new SampleJFrame(); J
-
I can't get my itunes to recognise my iphone. I have updated to the latest version of itunes. Please help me!!!
-
Error 36 when trying to copy itunes folder
I am not very computer savvy and have searched for some sort of solution to this issue. I have an ext. HD western digital and since mavericks I have had issues accessing this drive. It is very slow. So slow that it really doesn't work at all and I
-
How can a email I just saw disapear after I opened another app?
This happened two times today. One of them vanished in the trash, where I later found it ... by chance. I had opened them in the iPhone mail-App, not in the providers app ...