Problem trying touse stageWebView on flex mobile

Hi I've been trying to figured it out , but it seems I've been doing everything by the book, but nothing happens.
here is my code is on a <s:view> and there is no way to call the function, when I wrote public still nothing happens, I know that the answer is maybe easier as I tough.
<?xml version="1.0" encoding="utf-8"?>
<s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
                    xmlns:s="library://ns.adobe.com/flex/spark" title="Blog-FLS" activate="webView(event)">
  <fx:Declarations>
  <!-- Place non-visual elements (e.g., services, value objects) here -->
  </fx:Declarations>
<fx:Script>
          <![CDATA[
                    import mx.events.FlexEvent;
                    private var stageWebView:StageWebView;
                    public function webView(event:FlexEvent):void{
                              if (StageWebView.isSupported==true){
                                        stageWebView= new StageWebView();
                                        stageWebView.viewPort = new Rectangle(5,80,stage.width-10,stage.height-90);
                                        stageWebView.stage = this.stage;
                                        stageWebView.loadURL("http://google.com");
                              } else{trace("algo pasa") };
          ]]>
</fx:Script>
</s:View>
I don't know how to activate this on the view since it looks impossible to do it from the application itself some help will be appreciated
Gus

Try using viewActivate instead of activate

Similar Messages

  • Flex Mobile List Item Renderer problems

    i have flex mobile list created with item renderer,i remove individual item in flex mobile list,it is worked very well,but some times i double click action or another scroll event using in list, last item doesn't delete in flex mobile list.it is repeated again and again.so anyone this problem faced,give me a solution.
    i expect your feedback.Thanking You

    Hi Alex,
    I've searched a lot for that post (on this forum and on google). Not sure if this is the post you were talking about: http://tech.groups.yahoo.com/group/flexcoders/message/161146
    I have fixed the setter of the data not to also manage the state (I figured it was inappropriate there)... overrode the getCurrentRendererState, I'm managing the state staight from the data. When I run the following... All sold items show as sold... and normal states show as normal. When I try to hover over the normal state, it dosen't play the hovered state, and when I click to the selected state. These built in states don't work.
    override public function set data(value:Object):void {
         super.data = value;
         ticketNumber_ti.text = value.slots_id;
    override protected function getCurrentRendererState():String {
         var state:String;
         if (data.date_purchased != null) {
              state = 'sold';
              mouseChildren = false;
              mouseEnabled = false;
         }  else {
              state = 'normal';
              mouseChildren = true;
              mouseEnabled = true;
         return state;
    On another note, the states only update, once I start scrolling, everything updates... I tried to validateDisplayList() to the List after setting the dataProvider with no luck.
    Once I find a solution I will certainly add it to my Blog as I have not found a lot of solutions for this problem.
    Any help is grteatly appreciated.

  • Flash Builder 4.5.1 - Problem compile Flex Mobile release build

    I am building a flex mobile applicaiton using Flash Builder 4.5.1. The application works fine on the device (Nexus S) and desktop in the debug mode however, whenever I export the release build the app is not installed on the device automatically. When I manually install .apk it also fails (get Application not installed message with green check mark). Any thoughts?

    Getting a big closer... Compiled .swf using mxmlc, then manually packaged .apk without any issues... When I try to run: adb install -r myapp.apk: I get the following error:
              pkg: /data/local/tmp/myapp.apk
    Failure [INSTALL_PARSE_FAILED_NO_CERTIFICATES]
    Perhaps certificates are not respected?

  • Trying to use adobe air 17 in a Flex Mobile ap

    hello,
    My Flashbuilder is using  AIR 17 as is visible in AIR aps.
    However, my Adobe flex mobile app won't let me update a certain line in the .xml
    I want to change:
    <?xml version="1.0" encoding="utf-8" standalone="no"?>
    <application xmlns="http://ns.adobe.com/air/application/3.1">
    to
    <?xml version="1.0" encoding="utf-8" standalone="no"?>
    <application xmlns="http://ns.adobe.com/air/application/17">
    Yet when I try and debug, I get a popup window that says:
    Process terminated without establishing connection to debugger.
    invalid application descriptor: Unknown namespace: http://ns.adobe.com/air/application/17
    Launch command details:  "C:\Program Files\Adobe\Adobe Flash Builder 4.7 (64 Bit)\sdks\4.6.0\bin\adl.exe" -runtime "C:\Program Files\Adobe\Adobe Flash Builder 4.7 (64 Bit)\sdks\4.6.0\runtimes\air\win" -profile mobileDevice -screensize 480x762:480x800 -XscreenDPI 252 -XversionPlatform AND "C:\Users\l\Adobe Flash Builder 4.7\CSemt\bin-debug\CSemt-app.xml" "C:\Users\l\Adobe Flash Builder 4.7\CSemt\bin-debug"
    any help?

    Back in the day, you had to overlay the Flex and AIR SDks to make it work.  It may still be the case.
    i've since switched to pure AS3 projects since I didn't use any Flex components, so I don't follow this workflow anymore, I do this instead: Update the AIR SDK for ActionScript Projects | Flash Builder 4.7
    I remember following these instructions back when I was still overlaying the SDKs, maybe they'll help you:
    Overlay AIR SDK on Flex SDK | Flash Builder
    Obviously back up your existing SDK directory first....
    Good luck!

  • Incompatible signature after creating a new Flex mobile project in Flashbuilder 4.6

    When I create a new flex mobile project and try to build it right away it gives me this error
    1144: Interface method initialize in namespace mx.core:IUIComponent is implemented with an incompatible signature in class utest.
    I have tried reinstalling Flash Builder and even upgraded from 4.5 to 4.6 to try and resolve this problem.
    I have also tried using different versions of the Adobe Air sdk (I'm currently using Air 3.4).
    Here is the projects mxml file, if that helps although it doesnt have anything but the generated code.
    utest.mxml
    <?xml version="1.0" encoding="utf-8"?>
    <s:ViewNavigatorApplication xmlns:fx="http://ns.adobe.com/mxml/2009"
                                xmlns:s="library://ns.adobe.com/flex/spark"
                                firstView="views.utestHomeView" applicationDPI="160">
        <fx:Declarations>
            <!-- Place non-visual elements (e.g., services, value objects) here -->
        </fx:Declarations>
    </s:ViewNavigatorApplication>
    views.utestHomeView.mxml
    <?xml version="1.0" encoding="utf-8"?>
    <s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
            xmlns:s="library://ns.adobe.com/flex/spark" title="HomeView">
        <fx:Declarations>
            <!-- Place non-visual elements (e.g., services, value objects) here -->
        </fx:Declarations>
    </s:View>
    Also I am running Flash Builder 4.6 on Windows 7 32-bit
    Thanks in advance for the help
    Edit:
    I have now tried the flash builder 4.7 trial and even 4.6 on a different machine, both were clean installs, and I have found that when i create a new project it does compile
    until I get an error, and this can be any error, then after I fix that error it gives me the same error as before
    1144: Interface method initialize in namespace mx.core:IUIComponent is implemented with an incompatible signature in class utest.

    Hi Gsaison,
    Do you have any progress on these issues? Im working on the same solution right now (SWV + GoogleMaps JS v3 ) I've got some weird issue when i try to spawn a StageWebView inside a View on IOS, it appears inside a scroller and is not open for finger interaction anymore. I use the eskimo framework, but then again, nothing fancy going on there for the rest. I've tried all of the the stage.stageScaleMode options but non of them work. Got any help?
    Kind regards,
    Roy

  • Why am I getting-"The ExternalInterface is not available in this container" in Flex Mobile Project

    I am using StageWebView to show an HTML page. I want to call a function in my flex mobile project to be called from a JS function. Using ExternalInterface, I have 
       in Flex - 
        ExternalInterface.addCallback("myFunction",myFunc);
       in JS -
            function thisMovie(movieName) {
               if (navigator.appName.indexOf("Microsoft") != -1) {
                 return window[movieName];
               } else {
                 return document[movieName];
           function showAlert()
                  alert("Going to call AS function");
                thisMovie("ShowLocalHTML").myFunction("Hello");
                  return false;
    I am getting "Error: Error #2067: The ExternalInterface is not available in this container. ExternalInterface requires Internet Explorer ActiveX, Firefox, Mozilla 1.7.5 and greater, or other browsers that support NPRuntime." when trying to run the application.
    And my project targets Android platform. And  I have Mozilla, Chrome installed on my desktop - although I am not user if that is relevant to the problem.
    Please help in resolving this issue.

    Is there an alternative?
    I want to display a local HTML file and then allow for JS to Flex communication. I am new to Flex and AS. As per my understanding, StageWebView is the only way to
    show a local HTML file in a mobile project. If the script interface is not available - then I cannot achieve JS-to-Flex communication. So is there any other way to do this??
    Please help ...else I will have to abandon my foray into Flex, AS and go back to Android Java.

  • Flex Mobile Project only lists "Google Android" in Target Platforms

    I just downloaded the masters colection cs5.5 and im am using FlashBuilder 4.5.  When I create a new Flex  Mobile Project, only Google Android is a target platform.  I don't see  Blackberry or iOS as options.
    I do see Apple iOS when I create a mobile ActionScript project.
    This must be due to a configuration setting.  Can anyone help?
    i have already looked at this peron post and i have tryed all of the sollutions and none of them seem to work http://forums.adobe.com/thread/867857

    That didn't help me either.  Ultimately, here's what I did.
    I uninstalled and reinstalled the software
    After it was reinstalled, I updated to the 4.5.1 SDK PRIOR to doing any other software update.
    Then I updated the Software
    The software update found all new items and installed them properly (which is what I believe the issue is -- if you update prior to using the 4.5.1 SDK it doesn't install the required bits).
    Now it seems to be working for me.
    Not sure if that's the problem, but that's how I fixed it.

  • Flex Mobile 4.5.1: Package contents and URLLoader

    On Flash for web and desktop (Projector debugger), one can use a URLLoader to load local URLs (eg files off your hard drive).  This is very useful for some development purposes, as you just need to make sure any external files (JSON & PNG) are in the same relative path as the SWF, and you then don't need to worry about different code paths whether you're loading these external files from local storage or http.  URLLoader operates the same whether loading locally or remotely.
    Is there any way to easily get the same behavior on a Flex Mobile 4.5.1 app (specifically for an iOS target)?  Again, this is useful because in my live app, these external files will be loaded from our web server, but for testing purposes I would like to be able to run in a server-less mode and include them with the deployed debug IPA file.  My first problem is that I cannot seem to figure out how to deploy these files to the application in the first place - I tried adding my external-files folder to the Flex Build Path as an additional Source folder, but they still don't show up under the Package Contents for iOS tab.
    Any ideas?  Are there any include-extra-files-in-package options in the -app.xml? 
    Or is there no way to use URLLoader for local storage on mobile, and I am stuck with using Embed?  (I guess besides Embed I could manually deploy the files to the iOS file system and use the AIR api for access, but that's still a different code path, defeating my goal - we have a decent bit of code built around the idea that URLLoader is agnostic)

    Edit: Realized my original answer wasn't correct, the files were being pulled in from another setting.
    After some experimenting, the answer is YES, and it's actually a bit unexpected: Just in fact adding the external files folder to the Flex Build path | Source Path actually pulls them all in.  It seems those directories are passed to both mxmlc and adt.  Unexpected surprise.

  • Flex iPad Application : Run code before application enters background  Application Type: Flex Mobile Application Target Platform: iPad AIR Version: 4.0 Development Environment: Flash builder 4.6  I want to run some code just before iphone application goes

    Application Type: Flex Mobile Application
    Target Platform: iPad
    AIR Version: 4.0
    Development Environment: Flash builder 4.6
    I want to run some code just before iphone application goes into background. I need function similar to didEnterBackground
    of native xcode app
    (https://developer.apple.com/library/ios/documentation/UIKit/Reference/UIApplicationDelegat e_Protocol/Reference/Reference.h
    tml#//apple_ref/occ/intfm/UIApplicationDelegate/applicationDidEnterBackground:)
    I tried using devactivated function of flash.display.STAGE.
    I used following addEventListener:
    STAGE = this.parent.stage;
    STAGE.addEventListener(Event.DEACTIVATE, onAppDeactivated);
    It worked for me but only when device is connected to development environment in debug mode. When I create my release build
    it is not working.
    So how can I make sure that my code runs before application goes into background.

    Even I am facing almost same issue
    Problem installing Adhoc version to iPhone and iPad - Development Environment Is - Adobe Flash CS6

  • Flex Mobile Charts -- Less Than Symbol in Axis labels

    Hi,
       I am creating a Mobile Project and want to display a column chart. My problem is I want to display "<" in  Axis label of charts.But somehow its not working.I have tried using "&lt;" and is working fine in Web and Desktop project.But somehow it is not working in Flex mobile project. I have attached the source code for the same please help me to resolve this issue.
    Thanks & Regards
        Vishal Lad

    No attachment option found so pasting my mobile project code.I am doing same thing in Web and destop project this is working fine.But for mobile project somehow I am getting blank label.
    <?xml version="1.0" encoding="utf-8"?>
    <s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
    xmlns:s="library://ns.adobe.com/flex/spark" title="HomeView" xmlns:mx="library://ns.adobe.com/flex/mx">
    <fx:Declarations>
    <!-- Place non-visual elements (e.g., services, value objects) here -->
    </fx:Declarations>
    <fx:Script>
    <![CDATA[
    import mx.collections.ArrayCollection;
    [Bindable]
    public var expenses:ArrayCollection = new ArrayCollection([
    {Month:"&lt;200", Profit:2000, Expenses:1500},
    {Month:"200-400", Profit:1000, Expenses:200},
    {Month:">400", Profit:1500, Expenses:500}
    ]]>
    </fx:Script>
    <mx:ColumnChart id="myChart" dataProvider="{expenses}" showDataTips="true">
    <mx:horizontalAxis>
    <mx:CategoryAxis
    dataProvider="{expenses}"
    categoryField="Month"
    />
    </mx:horizontalAxis>
    <mx:series>
    <mx:ColumnSeries
    xField="Month"
    yField="Profit"
    displayName="Profit"
    />
    <mx:ColumnSeries
    xField="Month"
    yField="Expenses"
    displayName="Expenses"
    />
    </mx:series>
    </mx:ColumnChart>
    </s:View>

  • Flex Mobile : URLLoader bytesTotal always at 0 when loading file

    Hi !
    I'm trying to load external file with UrlLoader in a Flex Mobile Project ( Initialy it was with Data/Services Options of Flash Builder, but I have the same problem ). On the complete event, it work on the desktop ( bytesTotal, xml... ), but when i install my application on my nexus one ( air version : 2.5.0.1660 ), i've no data ( bytesTotal = 0 ), but the cache of the application has grown
    The application has these autorisations :
                <uses-permission android:name="android.permission.INTERNET"/>
                <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
                <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
    If someone can help me...
    Thx !
    Vince

    After messing with the URLLoader for a native windows AIR app I gave up on it. That object will return 200, ok, complete, while failing to do what it says it did.
    I never found any way to catch a real error from the server with any of the event listeners for URLLoader.  Instead I used HTTPService, it acutally returns useful data on server errors.  Here is an example, all this is tucked into my own class.
    var service:HTTPService = new HTTPService();
                   service.url = url;
                   service.resultFormat = HTTPService.RESULT_FORMAT_E4X;
                   service.method = URLRequestMethod.POST;
                   service.addEventListener(ResultEvent.RESULT,serviceResult);
                   service.addEventListener(FaultEvent.FAULT,faultResult);
                   service.send(vars);
    private function serviceResult(eResult:ResultEvent):void
                   var objResult:Object = eResult;              
                   if( objResult.result is XML )
                        xmlData = eResult.result as XML;
                        trace(xmlData);
                        dispatchEvent( new Event('eComplete') );
                   else
                        //something wrong
                        trace('BAD! No XML Returned: '+eResult.result);
                        dispatchEvent( new Event('eError') );
    private function faultResult(e:Event):void
                   if( e is ErrorEvent )
                        trace( ErrorEvent(e).text );                   
                   else if ( e is FaultEvent )
                        trace( FaultEvent(e).message.toString() );
                   else
                        trace( 'Unhandled error' );
                   dispatchEvent( new Event('eError') );

  • Flex Mobile Images

    Hi, I am unable to see my Images in the adobe flex mobile project. I am able to see the picture before load but once the program is run the image disappears? I have tried changing the picture. The source path and the source path in source code. I really do not see what the problem is the path must be correct because the picture would not appear. I also have tried embedding the picture which still does not work. Can anyone suggest any options for me please?
    The image is Source I have tried: -
    <s:Image id="pic" x="48" y="53" smooth="true" source="@Embed('Assets\cat.jpg')"/>
    Also attempted: -
    <s:Image id="pic" x="48" y="53" smooth="true" source="('Assets\cat.jpg')"/>
    In design the source: -
    Assets/cat.jpg
    Also: -
    @Embed('Assets\cat.jpg')
    Can anyone please help me as I am really struggling to find a soloution.
    The images are saved in the Assets folder

    Thanks. So size of the file really doesn't matter much when it comes to loading/performance because it's basically a local file (embedded with the apk) is it.
    Also, if my source image is a jpg file, should I convert it to a PNG?

  • Open PDF with Flex Mobile Project

    I want to be able to read PDFs inside a Flex Mobile Project (I'm working with Flash Builder 4.6 and Android and iPad).
    I've tried successfully stagewebview to load a pdf from a web server with this:
    webView = new StageWebView();  webView.loadURL("http://<url>/Paper.pdf");  webView.viewPort = new Rectangle(0, 100,this.stage.stageWidth, this.stage.stageHeight); webView.stage = this.stage;
    But what I really want it's something more visual. I mean, where you can create a flip book, go to page X, or similar. Something like this: http://devaldi.com/zine/NZ_Tourism_2007.php?ro=flash,html
    I've already tried FlexPaper, but Zine doesn't work on Flex Mobile Project.
    Do you know if there is something to do this? or how can I do this?
    Is there any native-extension or something?
    Thanks in advance

    Thanks Keith, I'll have a look at that. In addition to opening a PDF, I want to be able to encode an anchor id in to the open command to jump a specific anchor; I'd concluded that on iOS, until Adobe add decent url-scheme support, that was a no go - so I've been staring down the barrel of converting the .pdf to HTML and tidying up the inevitable issues manually. Here's hoping Print2Flash will help avoid that!

  • StageVideo with Flex Mobile Project on iOS

    In a Flex Mobile project using StageVideo, StageVideoAvailabilityEvent always returns StageVideoAvailability.UNAVAILABLE.
    I've been reading all day and it looks like StageVideo might not be supported with Flex projects, but I can't find a concrete answer.
    I need a definitive answer, using Flash Builder 4.6, AIR 3.1, and Flash Player 11, can StageVideo be used. If so, any help as to how to get this working would be greatly appreciated.
    Thank you in advance.

    After much trial and error, I finally have a definitive answer. The answer is yes, you can use StageVideo in a Flex Mobile project. To be honest I found StageVideo to be completely useless, at least for what I was hoping to use it for.
    The first big problem is that the StageVideo plays underneath all Flash content. Second, at least on iOS, there were no video controls. I suppose you could roll your own, but I didn't take the time to experiemnt with this. I ended up just using StageWebView.
    More information here: http://www.unfetteredthoughts.net/2012/01/12/embedded-h-264-video-on-ios-with-a-flex-mobil e-project/
    I hope that helps anyone else looking for this.

  • Can we integrate whatsapp in a flex mobile app????

    I am working on a text generator in flex mobile. I wanna share that text via whatsapp. How can i implement this?? Please help me.
    Thanks in advance.

    Thanks. I using StageWebView to display a local HTML file(file://). But while I tried adding ExternalInterface addCallBack code and tested in the emulator - got the following error
    Main Thread (Suspended: Error: Error #2067: The ExternalInterface is not available in this container. ExternalInterface requires Internet Explorer ActiveX, Firefox, Mozilla 1.7.5 and greater, or other browsers that support NPRuntime.)
    Does it mean ExternalInterface cannot be used in a Mobile project using StageWebView?

Maybe you are looking for

  • Unable to assign Chart of Depreciation to Company Code

    Dear Experts, I am trying to assign newly created chart of depreciation to my company code but system is not allowing me giving the following error message: "You cannot process company code ****, it contains assets". When I go for F1, then further it

  • Weird error when trying to log in Designer 10g in Windows XP Prof. SP2

    Hello, I'm having a problem to log in because the software responds with the following messages: ORA-12560: TNS: error in protocol adapter Cause: A generic protocol adapter error occurred. Action: Check addresses used for propel protocol specificatio

  • Change color of future typed text in a pasted document?

    How do I change color of future typed text in a copied document? Thanks. My son is doing online home schooling this year and has Study Sheets that he types in his answers.  Currently, he highlights his typed text then chooses the color.   Is it possi

  • Converting some special characters NON ASCI to ASCI

    HI Gurus, My Users copied some text from some other file and pasted in SAP in Infotype hrp1000 in a Text field. In the frontend of the SAP screen , the text looks good as English text. My program is retrieving that text and sending to AL11. If i open

  • Standard crm service tables

    Hi All, I need standard CRM tables list. could you please help me ths. Thanks, SK.