cancel
Showing results for 
Search instead for 
Did you mean: 

Problem passing int values to Flash Islands

Former Member
0 Kudos

Hi,

im developing a WDA with Flash Island embedded and i'm having problems passing integer values to the flex component.

Im using Flex 3.2 with Flex 3.6 Data visualization (I also tried compiling with Flex 3.0, Flex 3.5 and Flex 4.0)

The following piece of code does not work for me (it shows an empty table)

<mx:Script>
	<![CDATA[
		[Bindable] public var dataSource:ArrayCollection;
		[Bindable] public var ypos:uint;

		public function initApp():void{
			FlashIsland.register(this);
		}
	


	
		
			
		
	]]>

but if i only change ypos variable type from uint (or int, its the same) to String, then I have the data displayed correctly

		[Bindable] public var ypos:String;

In the WDA component controller the ypos field is defined as (TYPE I)

I know i can pass values as String and convert them to uint, but I'm wondering if I'm doing something wrong

Any suggestions?

Thanks

Manuel

Accepted Solutions (1)

Accepted Solutions (1)

thomas_jung
Developer Advocate
Developer Advocate
0 Kudos

ypos isn't the value of the column of hte dataSource itself. It is just an alias to hold the actual column name. It therefore must be type STRING. The columns in the dataSource will be created automatically with matching types from the WD Context - so they are int already if the context is type I. For instance send an alert or check the value of ypos in the debugger. You will see it contains the context attribute name of the matching column in the dataSource.

manuel_bassani
Contributor
0 Kudos

That's clear now, Thomas, thanks for the explanation

Have a nice day

Manuel

Answers (0)