Flash builder 4 file (mxml)

<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
			   xmlns:s="library://ns.adobe.com/flex/spark" 
			   xmlns:mx="library://ns.adobe.com/flex/mx" 
			   width="500" height="500"
			   initialize="application1_initializeHandler(event)">
	<fx:Script>
		<![CDATA[
			import mx.events.FlexEvent;
			import mx.rpc.events.ResultEvent;
			import mx.charts.series.PieSeries;
			import mx.charts.PieChart;
			
			[Bindable]
			private var myResult:String;
			private static var myBoolean:String;
			private var dataRequest:String;
			[Bindable]
			public var unikCounts:int;
			[Bindable]
			public var allMyCounts:int;

			protected function application1_initializeHandler(event:FlexEvent):void
			{
				myBoolean = this.parameters.myCookie as String;
				sendRequest('_unique')
			}
			protected function dataResponder_resultHandler(event:ResultEvent):void
			{
				myResult = event.result as String;
				if(dataRequest == '_unique')
				{
					unikCounts = int(myResult);
					sendRequest('_all');
				}
				if(dataRequest == '_all')
				{
					allMyCounts = int(myResult);
					
					var series:PieSeries = new PieSeries();
					series.field="number";
					series.labelField="descript";
					series.explodeRadius=.02;
					series.setStyle("labelPosition", "inside");

					chart.visible=true;
					chart.dataProvider=salesData;
					chart.width=440;
					chart.height=440;
					chart.series=[series];
					contentGroup.addElement(chart)
				}
			}
			private function sendRequest(_dataRequest:String):void
			{
				dataRequest = _dataRequest;
				if(dataRequest == '_unique')
				{
					if(myBoolean == "false")
					{
						dataResponder.token = dataService.addUniqueData();
					}
					else
					{
						dataResponder.token = dataService.getUniqueData();
					}
				}
				if(dataRequest == '_all')
				{
					dataResponder.token = dataService.addAllData();
				}
			}
		]]>
	</fx:Script>
	<fx:Declarations>
		<s:RemoteObject id="dataService"  endpoint="gateway.php" 
						source="SitecounterService" destination="SitecounterService"/>
		<s:CallResponder id="dataResponder" result="dataResponder_resultHandler(event)"/>
		<fx:Model id="numDistribution">
			<counts>
				<row>
					<descript>Unique counts: {unikCounts}</descript>
					<number>{unikCounts}</number>
				</row>
				<row>
					<descript>All counts: {allMyCounts}</descript>
					<number>{allMyCounts}</number>
				</row>
			</counts>
		</fx:Model> 
		<s:ArrayCollection id="salesData" source="{numDistribution.row}"/>
	</fx:Declarations>
	<fx:Style>
		@namespace s "library://ns.adobe.com/flex/spark";
		@namespace mx "library://ns.adobe.com/flex/mx";
		mx|PieChart
		{
			font-size:16;
			font-weight:bold;
		}
	</fx:Style>
	<s:Panel title="Page counts (Flash builder 4)" borderAlpha="0" backgroundColor="0xF9F5F1" 
			 width="450" height="450">
		<s:layout>
			<s:VerticalLayout paddingTop="20"/>
		</s:layout>
		<mx:PieChart id="chart"/>
	</s:Panel>
</s:Application>