[flexcoders] How to insert mobile ad?

2011-08-22 Thread luvfotography
Can someone recommend an easy way to serve ads in my flex mobile game?
(so I can make sow money)
Has any one used admob, mochiads, etc?  Do I need an actionscript API?
Thanks 




Re: [flexcoders] How to insert mobile ad?

2011-08-22 Thread Dave Cates
Hi,

We're currently using Admob via a web mobile system - just using stagewebview 
to display the ads via a php page on our server.

Admob sucks though as, at best, we get a 50% fill rate. Am looking at Smaato as 
an alternative as they have a wider spread of ads networks. You'd have thought 
Google would have their act together by now though!

Dave.

On 22 Aug 2011, at 08:14, luvfotography wrote:

 Can someone recommend an easy way to serve ads in my flex mobile game?
 (so I can make sow money)
 Has any one used admob, mochiads, etc? Do I need an actionscript API?
 Thanks 
 
 



[flexcoders] Re: Catching/Trapping Error #3003: File or directory does not exist

2011-08-22 Thread valdhor
What does model.networkDriveLetter actually hold? Is it just the drive letter 
or is the colon attached as well?

Perhaps the call is failing even before the resolve tries to happen.

You may like to check the code in resolvePath to see how it works and where it 
throws the error.

--- In flexcoders@yahoogroups.com, sdl1326 azsl1326-email@... wrote:

 Thanks for the reply. I tried the following listeners, all to no avail.
 File.desktopDirectory.addEventListener(IOErrorEvent.STANDARD_ERROR_IO_ER\
 ROR,onSourceFileIoError)
 File.desktopDirectory.addEventListener(IOErrorEvent.NETWORK_ERROR,onSour\
 ceFileIoError)
 File.desktopDirectory.addEventListener(IOErrorEvent.STANDARD_INPUT_IO_ER\
 ROR,onSourceFileIoError)
 File.desktopDirectory.addEventListener(IOErrorEvent.STANDARD_OUTPUT_IO_E\
 RROR,onSourceFileIoError)File.desktopDirectory.addEventListener(IOErrorE\
 vent.IO_ERROR,onSourceFileIoError)
 Suggestions?
 Thanks, in advance.
 
 --- In flexcoders@yahoogroups.com, Alex Harui aharui@ wrote:
 
  Try attaching a listener to File.desktopDirectory
 
 
  On 8/19/11 8:40 AM, sdl1326 azsl1326-email@ wrote:
 
 
 
 
 
 
  I am getting the following error:
 
  Error #2044: Unhandled IOErrorEvent:. text=Error #3003: File or
 directory does not exist
  How can I trap this error? I have tried using a Try/Catch as well as a
 listener - see code below:
 
 
 
  try {
 
  var sourceFile:File = new File();
 
 
 sourceFile.addEventListener(IOErrorEvent.IO_ERROR,onSourceFileIoError);
 
  sourceFile = File.desktopDirectory.resolvePath(
 model.networkDriveLetter + \\ + event.payload.asset_location );
 
  }
  catch(e:Error){trace('an error has occurred')};
 
 
  However, neither of these seems to trap the error. Suggestions?
 
  Thanks, in advance.
 
 
 
 
 
  --
  Alex Harui
  Flex SDK Team
  Adobe System, Inc.
  http://blogs.adobe.com/aharui
 





[flexcoders] View ViewNavigator component

2011-08-22 Thread markflex2007
Hi,

I try View and ViewNavigator for mobile application.I like it.

I am very like the features for View/ViewNavigator . but I need develop a web 
application now.

I get error when I use View component for Flex web app.

Do you think if I can use  View and ViewNavigator for web app? or some same 
features components. I need pushView and popView functions in my web 
application.

Please give me a idea. Thanks

Mark



RE: [flexcoders] Re: Flex 4 CSS

2011-08-22 Thread Davidson, Jerry
I tried both BorderContainer and Panel, but neither would display an
image.  I can get the background color to change, but not add an image.

 

Perhaps a skin will work, but I can't get it to work so far.  I've
replaced the two lines of CSS with the default class panel skin which
is over 300 lines long, includes three overrides and other methods and
still doesn't seem to have an ability to add an image.

 

Who would have guessed a simple image would bring Flex to its knees?

 

 

 

From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com] On
Behalf Of valdhor
Sent: Friday, August 19, 2011 1:59 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Flex 4  CSS

 

  

Instead of using mx:Canvas try using s:BorderContainer.

?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



fx:Style

.bgImage

  {

color: #DEDACF;

contentBackgroundColor: #DEDACF;

backgroundImage: Embed(BannerBackground.jpg);

backgroundImageFillMode: repeat;

}

/fx:Style



s:BorderContainer width=100% height=600 styleName=bgImage

s:Label text=CSS Background test /

/s:BorderContainer



/s:Application


Re: [flexcoders] Re: Flex 4 CSS

2011-08-22 Thread Alex Harui
Jerry, the spark theme doesn’t support backgroundImage.  Every capability has a 
cost, and we chose not to make the container backgrounds as heavy as the Halo 
theme.  It doesn’t matter how many lines of code are in the skin if it doesn’t 
include the logic to load and position images.


On 8/22/11 7:27 AM, Davidson, Jerry jerry.david...@illinois.gov wrote:






I tried both BorderContainer and Panel, but neither would display an image.  I 
can get the background color to change, but not add an image.

Perhaps a skin will work, but I can’t get it to work so far.  I’ve replaced the 
two lines of CSS with the default class “panel skin” which is over 300 lines 
long, includes three overrides and other methods and still doesn’t seem to have 
an ability to add an image.

Who would have guessed a simple image would bring Flex to its knees?




From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com] On Behalf 
Of valdhor
Sent: Friday, August 19, 2011 1:59 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Flex 4  CSS



Instead of using mx:Canvas try using s:BorderContainer.
?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



   fx:Style

   .bgImage

 {

   color: #DEDACF;

   contentBackgroundColor: #DEDACF;

   backgroundImage: Embed(BannerBackground.jpg);

   backgroundImageFillMode: repeat;

   }

   /fx:Style



   s:BorderContainer width=100% height=600 styleName=bgImage

   s:Label text=CSS Background test /

   /s:BorderContainer



/s:Application





--
Alex Harui
Flex SDK Team
Adobe System, Inc.
http://blogs.adobe.com/aharui


[flexcoders] repeater width problem

2011-08-22 Thread steveroger_flex
Hello Friends,

I am trying to implement one functionality using repeater.
But facing one problem.

Code snapshots.

public  var ArrData : Array = [{label: 'Option 1', value:'opt1'},{label:
'Option 2', value:'opt2'},{label:'Option 3',
value:'opt3'},{label:'Option 4', value:'opt4'}];

mx:HBox width=350 height=30
   mx:Repeater id=tRepeater  dataProvider={ArrData}
width=100% height=100%
 mx:Label text={tRepeater.currentItem.label} /
   /mx:Repeater
/mx:HBox

Labels are displed with array data using Repeater inside HBox.

Problem is, Labels go out of the HBox horizontal range.
I wanna to implement, if Hbox width is exceeded, Labels will start
occupying in next row.
Hbox width should be fixed at 350. Vertical Scrolling appear if labels 
exceeded from width range.

where I am doing mistake OR missing anything?

Thanks,

Steve.