Flex :: Datagrid - Pass A Parameter To ItemEditor?

Jul 19, 2010

I have a datagrid where one column calls a custom an itemEditor like;

<mx:DataGridColumn dataField="city"
width="150"
headerText="City"

[code].....

View 3 Replies


Similar Posts:


Flex :: DataGrid With Variable Custom ItemEditor On A DataGridColumn?

Jun 18, 2010

Is there anyway to create a custom item editor based on the dataField value? For example:

<mx:DataGrid editable="true" dataProvider="{_actionArr}" id="prop">
<mx:column>
<mx:DataGridColumn headerText="Component" editable="false" dataField="label"/>

[code]....

View 2 Replies

Flex :: DataGrid Lines Showing Through ItemEditor - Opaque?

Sep 18, 2010

I have a datagrid column as follows:
<mx:DataGridColumn
headerText="Description"
dataField="description"
editable="true"
editorXOffset="2" editorYOffset="2"
editorHeightOffset="20" editorWidthOffset="60"
itemEditor="com.jono.controls.DgItemEditor"
wordWrap="true"
/>

And a very simple DgItemEditor:
<?xml version="1.0" encoding="utf-8"?>
<mx:TextArea xmlns:mx="[URL]" wordWrap="true" backgroundColor="#FFFFFF" backgroundAlpha="1">
</mx:TextArea>

Basically, this allows for a small 'popup' when the user edits a cell in the datagrid, allowing for more space to type. The problem that I am having is that the datagrid gridlines show through the itemeditor - i.e. the itemeditor is transparent. Is there any way that I can force it to be opaque?

View 1 Replies

Flex :: Scrollbars In Dropdownlist Inside DataGrid ItemEditor Not Working

Aug 17, 2010

I have a DropDownList inside the itemEditor of my DataGrid. There are enough items in the DropDownList to justify scrollbars. You can see the scrollbars, and the mousewheel works fine. If you move the mouse over the scrollbars, they'll change appearance fine (mouseover is working). If you click on them, the DropDownList closes as if you'd clicked elsewhere in the data grid.

I've been experimenting with custom skins hoping to find a way to trap the mouse event, but have been unsuccessful.

FWIW, this is Flex4, as an AIR app.

Scratch.mxml (main code)

<?xml version="1.0" encoding="utf-8"?>
<s:WindowedApplication xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"

[Code].....

View 2 Replies

Flex :: Getting Error When Use Itemrenderer And Itemeditor Components In The Datagrid Column

Apr 11, 2011

[Code]...

ErrorStackTrace: ReferenceError: Error #1069: Property text not found on a.mxml.a_inlineComponent3 and there is no default value.

View 2 Replies

Flex :: Strange Copy/paste Behavior In Custom ItemEditor Component Used In A Datagrid?

Feb 10, 2011

I'm turning to you folks for answers because this really blows my mind... Let me explain:I'm using a slightly modified spark NumericStepper as an item editor in a datagrid. I had to modify the original because for some reason it's values only went up to 10.So i extended NumericStepper like so:

<?xml version="1.0" encoding="utf-8"?>
<mx:NumericStepper xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"

[code].....

View 1 Replies

AS3 :: Flex / Pass Parameter In Anonymous Function?

Aug 4, 2010

In as3, I am adding event listener and then attaching the anonymous function to it:[code]Now this whole piece of code is looped n times. Now, I have n myBoxes and whenever I roll my mouse over the box, it should alert the name. But, what I see is that the last value of count is used by each box. How can I pass parameter or value to the anonymous function? ( as roll over , I believe, expects only one variable)

View 2 Replies

Actionscript 3 :: Pass Parameter In Flex NativeProcess?

Jul 8, 2010

I want to pass two parameter to nativeProcess. While i am running exe file using windows command with parameter, it is working. Command for window is "abc.exe a.txt b.txt"How can I pass two parameters to the exe in that format using flex nativeProcess?This is what I have so far:

<?xml version="1.0" encoding="utf-8"?>
<s:WindowedApplication xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"

[code]....

View 9 Replies

ActionScript 3 :: Flex Pass Parameter To Custom Component

Feb 11, 2011

I have a custom component written in action script (no UI). I am instantiating this component in an mxml file which is present in a library project. The custom component has a constructor which takes one argument. The library project is used in some other web project from where i pass a variable to this mxml file.[I have linked source of the web project to source of library.].

I have a static variable in my library project which holds the reference of the current object of the project. I need this static variable in order to use properties present in the mxml file. I am unable to use the property sent from the web project in the constructor of the custom component, but able to use the same in some other function present in the custom component.

View 1 Replies

Actionscript :: Pass Parameter To Complete Event - Adobe Flex

Apr 4, 2011

I'm using an HTTP request to download a image in binary format. When the downloading is complete, I want to process it, but I also want to pass the image's ID to the complete handler function.

[Code]...

View 2 Replies

Flex :: Pass An Extra Parameter To Callback Event And Have It Evaluate Early?

Jun 30, 2011

For example:

for(var i:int=0; i<someArray.length; i++)
{
var loader:Loader=new Loader();
loader.load(new URLRequest("http://testurl.com/test.jpg"));

[Code]....

The second paramter (i) for imageLoaded is always 1, I guess because i no longer exists and is defaulting to 1. Is it possible to get that second paramter to be evaluated when the load is started rather than on complete?

View 2 Replies

Actionscript 3 :: Flex - Selection In Flex Datagrid Does Not Pass The ValueObject To SelectionChangeHandler Function

Aug 11, 2011

I have a TabNavigator, and each tab is a Module. One of the modules is labelled Units and the full code of the module is posted in this post. There are several problems:

1) Forms are not populated with data from the datagrid selection.
2) Selecting a row and clicking delete gives the very-common error: TypeError: Error #1009: Cannot access a property or method of a null object reference.

A trace on the valueObject unit within the selectionChangeHandler function gives NULL. Why? Note: In other modules (other tabs of the TabNavigator), I have DropDownLists populated with units. This means that the valueObject Unit is defined in the other modules. However, valueObjects should be private to modules, and not shared.

[Code]....

View 1 Replies

Flex :: Pass An Edited Flex Datagrid To A CFC To Insert To A Database?

Nov 3, 2009

I have a datagrid which is editable and I need to send that back to the database via a CFC for insertion into the database after all the editing is complete. Dumping the array collection to cfdump tells me that I have an array with items and a structure but i cannot understand how to "loop" through each and insert into the DB.There seems to be very little written which actually works! My MXML and CFC are below but give me the error of "You have attempted to dereference a scalar variable of type class coldfusion.runtime.Array as a structure with members." -which is nice

[Bindable]
private var getconsent:ArrayCollection = new ArrayCollection([
{LocationName:'Service A', Contact: 'Bob Jones' },

[code].....

View 3 Replies

Flex :: Datagrid - Pass A GridItemRenderer The DropDownList's DataProvider?

Oct 26, 2011

I need to display DropDownLists in a column of a DataGrid in my Flex application. Here is what I am doing:

First, I have a item renderer function that creates a custom item renderer, and passes it a property that is an IList that will be used as the dataProvider of the dropDownList:

private function rendererFunction(item:Object):ClassFactory {
var itemRenderer:ClassFactory = new ClassFactory(AudActionDropDownIR);
itemRenderer.properties = {AudActionData: AudActionData};

[Code]....

First, how can I call the init function when the renderer is created? Second, when I set the column's itemRendererFunction="rendererFunction", the app will not launch, a white screen comes up. But when I set itemRenderer="components.AudActionDropDownIR", the app will launch, but of course there is no data in the dropdown list.

View 1 Replies

Flex :: Datagrid - Pass An Array Of Values From One Mxml Component To Another?

Oct 13, 2009

I have a mxml component with a datagrid listing project names and code versions. I have the selected projects from the datagrid binded to a public variable named "selectedProjects". But how to access this variable in another mxml component. I want the selected project's name in that component's text area. I even created an instance of the first component and using that called the selectedProjects variable. But I do not get the value updated in the text area.

This is the code for the first component where I get the selected projects name in a variable:

<?xml version="1.0" encoding="utf-8"?>
<mx:TitleWindow xmlns:mx="http://www.adobe.com/2006/mxml"
creationComplete="handleCreationComplete();"
width="800" height="600">

[Code].....

I was trying to update the value of the selected projects in the text area of Id "projDocs", But I do not get it..

View 1 Replies

Call A Function With Event Parameter When Have No Event Parameter To Pass?

Aug 14, 2009

Forgive me for this stupid noob question but I want to call a function (loadList) that originally gets triggered after a mouseevent from another function (addToXML) that does not have an event.

The loadList function takes info from a XML var, sticks it into an array which then gets loaded into a tile list and that is working fine.

The addToXML function when called adds elements to the XML var after which I want to call the first function with the event parameter so it refreshes the items in the tile list.

I know it can do this by creating a new array and loading that into the tile list in the addToXML function, but it be much simpler to just recall the function.

I have tried things like

Code:
addToXML.addEventListener(Event.COMPLETE, loadList);

but all the event constants I have tried give me error messges like "1061: Call to a possibly undefined method addEventListener through a reference with static type Function."

View 3 Replies

Flex :: How To Prevent Itemeditor Destruction

Nov 24, 2009

My custom item editor opens a titlewindow (too much stuff to show in an inline editor) which obviously steal the focus, so I get a itemeditend event and the datagrid destroy the editor at the wrong (for me) time. I think to have to keep the itemeditor alive until the titlewindow job is done, but how? DataGridEvent reason is "other" and livedocs said preventDefault() can't help.

View 1 Replies

Flex :: Difference Between ItemRenderer And ItemEditor?

Dec 24, 2009

What is the Difference between ItemRenderer and ItemEditor?And When ItemRenderer is initializing and loading?

View 1 Replies

Flex :: Commit New Value From ItemEditor Before ItemEditEnd Event

Sep 7, 2009

I have a DataGrid, with itemEditor as NumericStepper in a few columns. When a value in the DataGrid is edited, I would like to update several values displayed on the screen, and so want to call a updateValues() function.First, I added this function to itemEditEnd event of the DataGrid, but the function is getting called before the new value is updated into the dataProvider and hence, the values I have in the function are the old values. Is there any other event that is fired after the values are updated into the dataProvider? or am I missing something?Second, I tried putting this function in the change event of each itemEditor (duh!), but then again, the change event is fired, but the values in the dataProvider are the old ones.Is there any way I can make the function updateValues() be called, every time a value is edited AND updated into the dataProvider, because there's where I am taking the values from?

View 1 Replies

Flex :: Trigger An ItemEditEnd Event Within The ItemEditor

Sep 29, 2010

This might be an easy one for you DataGrid experts out there. I following an example for adding rows to a DataGrid dynamically from within a row

[URL]

My tweak that I am trying to acoomlish, is to have a custom itemEditor that is a form with two TextInputs and an OK button. For the life of me I can't get that button to trigger the DataGrid's itemEditEnd event where I have some processing before I call destroyItemEditor. I tried dispatching the event myself directly but got a strange error in DataGrid's updateDisplayList saying editedItemPosition was null (editedItemPosition.rowIndex).

View 2 Replies

Flex :: Spark DropDownList As ItemEditor Within AdvancedDataGrid?

Mar 11, 2011

I'm trying to use the Spark DropDownList as itemEditor in an AdvancedDataGrid. Howerver, I've stumbled onto two issues:Clicking on a item in the DropDownList changes the selected row in the ADG. You can see this behavior by compiling the code from below and executing the following steps.The value changes from "A" to "C" and Row 3 is the selected row in the ADG. It looks like the mouse click in the DropDownList is also handled by the ADG itself which changes the selected row accordingly. I couldn't figure out a way to prevent this. The expected behavior would be that row 1 is still selected after the DropDownList has been closed.Clicking on the scrollbar of the DropDownList closes the DropDownList. (I just found the solution to this problem in the relatated questions while writing this: Scrollbars in dropdownlist inside DataGrid itemEditor not working)

Application
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"

[code].....

View 2 Replies

Flex :: ItemRenderer Shows Through ItemEditor On AdvancedDataGrid

Apr 5, 2011

When not editing the cell, it shows a centered date as plain text. When editing, it shows a DateField editor. The second example is exactly the same as far as I can tell, other than the fact that it is an AdvancedDataGridColumn. Using that code with an AdvancedDataGrid, when I go into edit mode I can see the text from the normal item renderer behind the DateField editor (between the text input and calendar icon).

Example 1:

<mx:DataGridColumn id="endColumn"
dataField="endDate"
headerText="End"

[Code]....

View 1 Replies

Flex :: ItemEditor In AdvancedDataGrid When Using Hierarchical Data As DataProvider

Mar 23, 2011

Following is the sample code. While I start editing either in optionId column or option column, the other rows of the same column are also get affected and reflecting the same value. But when I am editing in other columns it is working fine... Don't know the reason.

[Code]...

View 1 Replies

AS3 :: Flash - Pass Parameter By Value?

May 6, 2010

im having problems with the following code:

for (var i:Number=0; i<numFaces;i++){
var faceLoader:Loader = new Loader();
faceLoader.contentLoaderInfo.addEventListener( Event.INIT,
function(fle:Event){

[code]....

The problem is that im sending the variable i to the function LoadCara on every iteration, and its always called with the last value of i. I would like this function to be called with the appropiate index.

View 2 Replies

Actionscript 2.0 :: Get URL Parameter (Pass It From HTML To Swf)?

Jun 14, 2009

I'm trying to get a URL parameter in my flash...The parameter is a xml url...
 
testXML = new XML();
testXML.load(xmlurl);I tried every code I can find on the web and couldn't find a solution to get xmlurl
  
I tried var xmlurl:String = String(_root.loaderInfo.parameters.xmlurl); but it didn't work...
_global.xmlurl didn't work either
 
Here is my HTML:
 
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="590" height="300" id="test" align="middle">
<param name="allowScriptAccess" value="sameDomain" />
<param name="movie" value="test.swf?xmlurl=data.xml" />

[code]....

View 16 Replies

ActionScript 3.0 :: Pass A Parameter In A Class?

Dec 16, 2011

I have seen this code in ultitouch gesture samples. But I don't kno how can I pass a bitmap parameter to the statement  [Embed(source="imagenes/prueba.jpg")], how can I use this code with other bitmaps using parameters in this class?
 
package
{
import flash.display.Bitmap;
import flash.display.Sprite;

[Code]....

View 4 Replies

Pass Array For Inspectable Parameter?

Jun 21, 2010

When I create a custom component, I define a property which is array that could accept values from the enumeration, see code below:[code]...

I would like to know how I can pass array of values to my component from MXML application that uses my custom component.

View 1 Replies

Actionscript 3 :: Pass (MovieClip) As A Parameter?

Mar 14, 2011

How can I pass the keyword this OR an instance name as a parameter inside a function?

function (reference:InstanceName):void // kind of what I want
{
reference.gotoAndPlay("frameLabel");
}

View 2 Replies

Php - AIR Application And HTML Pass Parameter?

Jan 18, 2012

I have an AIR application that is downloaded from a webpage. In order to download the application, one must be logged in. I would like the first time the user opens the application, to be able to acces the userId that was logged in.

Is there any way do pass that information?

View 2 Replies

ActionScript 3.0 :: Pass MouseEvent As Parameter?

Oct 12, 2008

I would like to pass a mouse event : MouseEvent.CLICK as a parameter.

example:

ActionScript Code:
activateEvent(MouseEvent.Click,clickedEvent);
function activateEvent(event:MouseEvent,destination):void{[INDENT]

[Code].....

View 6 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved