flex4

Duplicate Flex Sessions With Cross-Domain Requests

有些话、适合烂在心里 提交于 2019-11-28 08:41:44
问题 When I make a request locally, I have no problems at all maintaining my FlexSession; however, when I make a request from another computer, it creates duplicate FlexSession for every request. I noticed the JSESSIONID is different for each request which is what's probably causing the duped sessions. But I have no idea why this is happening. The specific error I get is: Channel.Ping.Failed error Detected duplicate HTTP-based FlexSessions, generally due to the remote host disabling session

Custom Preloader in Flex 4?

断了今生、忘了曾经 提交于 2019-11-28 07:53:45
Has anyone successfully implemented a custom preloader in Flex 4? In my experience, when I specify a custom preloader using the preloader="com.foo.MyPreloader" in the Application tag, the preloader does not display until the SWF is completely downloaded, defeating the purpose of the preloader! Perhaps this is a bug in the still-beta Flex 4 framework? Simon Lenoir I've been using this example in many Flex3 projects. It's still working with Flex4 sdk: I can remember where I get it from. And you are right when you say it's important that this script is NOT referencing anything... <s:Application

Error migrating Flex 3 to Flex 4

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-28 04:53:29
问题 I imported my Flex 3 project to Flex 4 and removed all the errors and warnings listed in Flex 4 problem windows. I am having the following error in Flex 4 when launching my application. What could be the cause of this? Error: Compatibility version has already been read. at mx.core::FlexVersion$/set compatibilityVersion()[E:\dev\4.x\frameworks\projects\framework\src\mx\core\FlexVersion.as:254] at mx.core::FlexVersion$/set compatibilityVersionString()[E:\dev\4.x\frameworks\projects\framework

Flex 4.5 - to long build process

為{幸葍}努か 提交于 2019-11-28 02:19:05
We are developing an app using flex 4.5. The app runs just fine (no performance issues at all) but it takes us forever to compile and build it. A minor change, like just add a comment or press enter in an mxml file and rebuild takes about 3 minutes. You just cant work that way. It is a large project with about 1300 files. We also use Parsley as IOC container and a beat of cairngorm navigation. We also use Maven (Flex mojos) but I am talking about a normal eclipse build (Ctrl + B). We separated some of the code to a different SWC and all of our graphics are stored in a different resource SWF.

Actionscript's ExternalInterface.addCallback only working locally, not in production

淺唱寂寞╮ 提交于 2019-11-28 00:53:16
问题 In my Flex app, I need a Javascript control to call one of my Actionscript methods. Simple enough, according to the Flex/Actionscript documentation, I wrote this in my Actionscript code: if (ExternalInterface.available) ExternalInterface.addCallback("setName", setNameInActiveWindow); In the Javascript control I wrote: document.getElementById('FlexAppId').setName(name); Works great. Exactly as expected, so I went to production. But it doesn't work in production :(. Same exact code... I can't

Free Flex IDE's

ε祈祈猫儿з 提交于 2019-11-27 23:34:39
问题 could you recommend some good alternative Flex IDE? I am interested in free editions mostly but I will also take under consideration the paid ones. Thanks 回答1: You should give a try to FlashDevelop and FDT. FlashDevelop is free. http://www.fdt.powerflasher.com/ http://www.flashdevelop.org/wikidocs/index.php?title=Main_Page Rob 回答2: FlashDevelop is free, however I'm not a fan of their Flex support. It's better for straight actionscript development. There's also the following IDEs: FDT Flash

Flex 4: Setting Spark List height to its content height

霸气de小男生 提交于 2019-11-27 22:10:28
问题 How to set a Spark List height to the height of its content? Tried this: var lastRow:IVisualElement = myList.dataGroup.getElementAt(myList.dataGroup.numElements - 1); myList.height = lastRow.y + lastRow.height; It works in case of a single item, but lastRow is null in case of more items. 回答1: In mxml you can do it like so: <s:List width="100%"> <s:layout> <s:VerticalLayout useVirtualLayout="false" requestedMinRowCount="1"/> </s:layout> </s:List> You set the requestedMinRowCount or the

How to send PUT HTTP Request in Flex

狂风中的少年 提交于 2019-11-27 17:03:10
问题 I want to send HTTP PUT Request on one URL to update that content of XML via using API. URL is like this: https://domainname.com/someurls/id.xml I want to update that content. But When I am sending this PUT request, I have seen that in Network Monitor of Flex 4, Its going as the POST request on this web, while I am setting method as PUT in HTTPService variable. So I am getting error. So is there any way to send the PUT request on the web ? Or Is there any special header to set PUT method ? I

Scroll to selected item in Flex 4 Spark List component

只谈情不闲聊 提交于 2019-11-27 15:38:17
问题 I'm setting selected element in s:List component with Actionscript, it works, but List doesn't scroll to selected item -- need to scroll with scrollbar or mouse. Is it possible to auto-scroll to selected item ? Thanks ! 回答1: Try the s:List method ensureIndexIsVisible(index:int):void. 回答2: For Spark: list.ensureIndexIsVisible(index); 回答3: This function will scroll to the top of the list in Flex 4+. It takes in account the height of the item, so it will work for lists with different items with

Flex's FileReference.save() can only be called in a user event handler — how can I get around this?

感情迁移 提交于 2019-11-27 14:05:52
I need to call FileReference.save() after a web service call has completed, but this method has a restriction: "In Flash Player, you can only call this method successfully in response to a user event (for example, in an event handler for a mouse click or keypress event). Otherwise, calling this method results in Flash Player throwing an Error exception." (from the documentation here ) This restriction is a bit vague. Does it mean that I can only call the FileReference.save() method from within an event handler function that is registered as a listener for certain types of user events? If so