Re: [flexcoders] IP adress for Language
Locale is the only thing that really works. IP/Country is fine if you have to model different business processes depending on the location (VAT tax vs Sales Tax). Export restrictions, etc etc. Remember, just because you know they might be in France, doesn't mean they don't prefer English. Over half the computers in Quebec are set to French in a predominately English speaking country. Locale is a user determined setting and using it allows you to accomodate their preferences. On Jan 20, 2010, at 7:58 AM, Christophe wrote: Hello, I have a bilingual Flex application. French and English. How to automatically set the French or English version in function of the IP adress localisation of the client PC ? Thank you, Christophe, Kevin F. Benz kb...@kbenz.com (425) 785-7100 http://www.kbenz.com http://www.facebook.com/kbenz http://www.linkedin.com/in/kbenz We can't solve problems by using the same kind of thinking we used when we created them - Albert Einstein
Re: [flexcoders] Caringorm vs PureMVC
I prefer PureMVC as if you have any multi-platform development (say Flex and PHP, Flex and Java), there are PureMVC implementations for each platform. You can leverage PureMVC knowledge across platform teams, (hopefully) get better code, implement more cohesive standards, manage risk etc, etc etc. If developers cross teams, they are better prepared.KOn Jan 7, 2010, at 4:00 PM, Patricia Han wrote: Hi Everyone,I need to pick up a framework to use, either Caringorm or PureMVC. Any suggestion on this?Thanks for any advice.Patricia Han Kevin F. Benzkb...@kbenz.com - (425) 785-7100http://www.kbenz.com - http://www.linkedin.com/in/kbenzbegin:vcard version:3.0 prodid:Microsoft-Entourage/12.17.0.090302 UID:C3AAA4E9-F33F-44F1-BDA3-4FB66E5D3D25 fn;charset=utf-8:Kevin Benz n;charset=utf-8:Benz;Kevin;;; nickname;charset=utf-8:Rusty Zoomer title;charset=utf-8:President CEO org;charset=utf-8:InterKnack Corporation; note;charset=utf-8:Skype-In: (425) 296-6961\nLinkedIn: http://www.linkedin.com/in/kbenz url;charset=utf-8;type=home:http://www.kbenz.com adr;charset=utf-8;type=work:;;13400 NE 20th Street\, Suite 49;Bellevue;WA;98005-2026;United States of America label;charset=utf-8;type=work:13400 NE 20th Street\, Suite 49\nBellevue\, WA 98005-2026\nUnited States of America adr;charset=utf-8;type=home;type=pref:;;14802 SE 66th St;Bellevue;WA;98006;United States of America label;charset=utf-8;type=home;type=pref:14802 SE 66th St\nBellevue\, WA 98006\nUnited States of America tel;charset=utf-8;type=home:(425) 747-2450 tel;charset=utf-8;type=work:(425) 785-7100 tel;charset=utf-8;type=work;type=fax:(425) 401-1840 tel;charset=utf-8;type=cell:(425) 785-7100 email;charset=utf-8;type=internet;type=pref;type=work:kb...@interknack.com email;charset=utf-8;type=internet;type=work:kb...@kbenz.com X-ms-imaddress;charset=utf-8;type=home;type=pref:kb...@interknack.com (MSN) end:vcard
RE: [flexcoders] try, catch, finally ...
Try-Catch blocks are an absolute necessity as without them, you are putting the operation of your software into the hands of user input errors, http errors, unintended consequences as well as the myriad of things that exist outside the Happy Path. As functions/methods only give you one return object, it is common practice to throw custom errors/exceptions as they are a great mechanism for handling dynamic environments. To answer your second question about a try-catch without statements in the catch block. If this method is nested inside of another try-catch block, then an exception here will be swallowed and not be caught in the calling objects try-catch. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of SJF Sent: Tuesday, March 03, 2009 6:54 PM To: flexcoders Subject: [flexcoders] try, catch, finally ... Technically, it's good practice/professional to use try-catch-finally blocks in your actionscript logic. This ensures a robust, easily debugg-able application. However, can anyone comment if they actually use try-catch-finally or whether anyone is for or against it's use. I ask because I've received an application (which streams vidoe) that was blowing out numerous users CPUs to 100%. Upon further investigation, it appears that a netstream event is firing 20 times a second, and within the listener (listener function that is) for the event, there is a try-catch-finally block. I removed the try-catch-finally and CPU usage halved on my machine. Anyone care to comment for or against try-catch-finally and it's use. Steve. -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. image003.jpgimage004.jpg
RE: [flexcoders] Credit card processing in Flex
I would look at the authorize.net documentation as they present the most generic methods for HTTP based authentication. If you are talking about a client-side processing solution, it can be accomplished but a bad idea. SWF's can be easily reverse engineered exposing API keys, hash entries, merchant account identities and credentials to external access. Traditional non-API Wallet approaches (standard PayPal, Amazon FPS, Google Wallet) cannot exist in a client only solution as they require a post-back URL with which to transact. The only secure solution has a server acting as a gateway to the payment service with the Authorize.net documents providing many resources. Other payment aggregators offer likewise documentation such as Cybersource, Paypal (both Wallet and API). A server hides the specifics (code and metadata) from the peering eyes of those interesting in subverting your payment service. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Scott Sent: Wednesday, March 04, 2009 7:09 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Credit card processing in Flex Anyone have a website or information that references how to process credit cards through flex? Thanks Scott -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. image001.jpgimage002.jpg
RE: {Disarmed} RE: [flexcoders] Credit card processing in Flex
If the browser hosting your Flex component is connected in a HTTPS session, then yes. I'm not aware of being able to start HTTPS communication from a HTTP session. I believe that the SSL key (session in place) needs to be in-place before you do your submit so posting blindly to a HTTPS URL is not necessarily secure. Of course, the ugly solution, a popup HTML window doing HTTPS directly. You can also encrypt yourself in Actionscript with as3crypto (Google code) although this might violate PCI/SET standards. In Air, you can start an HTTPS session of its own. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Scott Sent: Wednesday, March 04, 2009 8:24 AM To: flexcoders@yahoogroups.com Subject: RE: {Disarmed} RE: [flexcoders] Credit card processing in Flex I plan on having the server process the credit card order. However, I still have to pass the credit card information securely to my server. The other response refers to sentourl so I'll look into that. Is there any other methods to send information securely to my server? sj From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Kevin Benz Sent: Wednesday, March 04, 2009 10:00 AM To: flexcoders@yahoogroups.com Subject: {Disarmed} RE: [flexcoders] Credit card processing in Flex I would look at the authorize.net documentation as they present the most generic methods for HTTP based authentication. If you are talking about a client-side processing solution, it can be accomplished but a bad idea. SWF's can be easily reverse engineered exposing API keys, hash entries, merchant account identities and credentials to external access. Traditional non-API Wallet approaches (standard PayPal, Amazon FPS, Google Wallet) cannot exist in a client only solution as they require a post-back URL with which to transact. The only secure solution has a server acting as a gateway to the payment service with the Authorize.net documents providing many resources. Other payment aggregators offer likewise documentation such as Cybersource, Paypal (both Wallet and API). A server hides the specifics (code and metadata) from the peering eyes of those interesting in subverting your payment service. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Scott Sent: Wednesday, March 04, 2009 7:09 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Credit card processing in Flex Anyone have a website or information that references how to process credit cards through flex? Thanks Scott -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. image001.jpgimage002.jpg
RE: [flexcoders] flexlib and subversion
The metadata for SVN will conflict trying to cover two repositories in the same source directories. There are a couple of ways to overcome this. The first (and probably least risky) would be to use build automation with Ant and have your Ant scripts copy over your source to a shadow directory and have that directory be the local home for one of your repositories. The risks are getting that automation to see new package paths. I suppose rsync could help as well but I like the one tool approach for build. The second and pretty nasty is to swap out the metadata.. This is a bad idea. From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of arieljake Sent: Monday, March 02, 2009 8:31 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] flexlib and subversion i'm new to subversion, so i need some help understanding how to do this: I want to attach my local source to the flexlib repository on google code so i can detect changes to the library, but also... I want to attach my local source of flexlib to my own projects repository so that other developers can use the modified flexlib i have. how do i accomplish this? -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. image001.jpgimage002.jpg
RE: [flexcoders] Multiple developer environment setup with subversion and all offsite
Where to start.. First and foremost, the changes you are contemplating are an absolute necessity for a growing organization as well as, in the end, deliver manageable projects in the long term. Common development environment configurations: 1. Speeds the ability of new developers to come up to speed as you have the opportunity to document your configuration. 2. Eases the ability to return to an archived project and be productive. 3. Facilitates uniform build scripts (for scripted builds which are really nice). The larger your projects, the more you will want more and more automation. 4. Facilitates collaboration. Subversion: Your developers don't have to have every line of code in every project. In our Subversion repository we have probably 75 different projects (Flex, Java, .NET) across our development teams and product groups. Each developer checks out whatever project they are working on at the time. For example, a typical Flex project for our group is built from 3-4 subversion projects. This sounds like a lot of work, but when you get to building shared libraries, you will easily see where this approach has benefits. Your biggest issue to deal with in advance is to develop the rules/discipline necessary to make the team work together. There is nothing worse than a developer that infrequently checks-in as the risk of collision and re-work is magnified as the time between check-ins increases. You have to approach SCM as a collaboration mechanism and set policies accordingly. This means that you must develop standards that deal with the process of software development unlike anything you have done before. Common Rules: * Designate a person to perform Build Master/SCM Owner tasks (tags, branches, merges) * Frequent Check-ins * Prior to a check-in, a developer MUST update to the current revision and perform flexuint/acid tests verifying that the inbound changes don't break the build. * A developer who has checked in code breaking the build must fix the build immediately (before going home) Depending on Internet Connections: Although it's hard to accomplish and keep up, I like having local web servers and app servers. If that is too problematic, most developers use a single service over and over meaning for a majority of the time, they could consume a local XML document. Figure the services aren't going to be done at the same point the Flex side is ready to consume them anyway. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Link Mckinney Sent: Saturday, February 28, 2009 1:51 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Multiple developer environment setup with subversion and all offsite We are currently looking to start using subversion for our flex application and other web applications and would like to get some feedback on how you would set our environment up. We all work from home, and we have a dedicated production/development server. It is currently only me who is developing all the web and flex applications, but my boss has told me we are getting way too busy now for just one developer. I have a local development environment that I develop and test locally, then when I am finished with my tasks given and want my boss to finally look and test my work, I upload it to the test server. When the test is completed, we then promote to the production server. My problem lies at, 1). if we go to multiple developers, then they would also have to set up their local environment like mine and keep our code in their environment. 2). If we created the remote developer server then you are really depending on your internet connection. if that goes then you cannot develop. But on the flip side, all of our code would rest on our development server and not in their environment. We currently use Flex Builder 3 and Dreamweaver. if we choose option 1 then this would be the developers requirements Flex Builder 3 with Tasktop connector for bugzilla and subversive for subversion ColdFusion 8.1 developer edition MYSQL 5.1 with schema that we provide Apache 2.2 if developer is on mulitple projects with us. I would like to get some input on how you would solve this problem. Thanks Link -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean.
RE: [flexcoders] Calling C++ app or service from flex on Mac
I have been moving forward with binding C++ objects into AppWeb which allows you to bind native DLL's (C or C++) into a pretty lightweight HTTP Server and calling it with an HTTP client. AppWeb is pretty neat as it has a rudimentary scripting language. K From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Priya Shah Sent: Sunday, February 22, 2009 7:50 AM To: flexcoders@yahoogroups.com; silva...@yahoogroups.com Subject: [flexcoders] Calling C++ app or service from flex on Mac Hi everyone, I am in dire need of being able to call a C++ app or service on Mac from flex. I am willing to go the AIR way for this though that's not optimal. I have spent some time trying to figure out the Netscape plugin architecture which is supported on safari but it's sub-optimal for me to go that route. I already have a C++ dll that I have invoked with flex on the Windows side using an Active/X plugin successfully. Now I need to compile the dll into some format on Mac and then communicate back and forth with flex. I have seen some open source bridge projects that enclose flash player in an MFC object but that doesn't help me on mac. Is it as simple as doing some Netstream class from flex to connect to either an app or a service (if there are services on Mac like there are on Windows) and just do a localhost communication back and forth? If so, what are the limitations of such approaches? Any sample apps out there? Regards Priyanka -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean.
RE: [flexcoders] Flex server language
My thoughts.. Learning Java makes you a better Flex developer. Learning Java should make you a better OOP developer (which makes you a better Flex developer). From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of bsyyu Sent: Wednesday, February 18, 2009 4:32 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Flex server language currently, I am using PHP as server language. In fact I would like to learn other server language in combination using Flex. Any suggestion such as .NET, coldfusion or JSP. -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. image001.jpgimage002.jpg
RE: [flexcoders] Prob with CopyTo in AIR[getting File or directory does not exist Error]
You need to use the HTTP objects to download the file and save it as a local file. File which creates a reference to the file is incompatible with the stream based HTTP. As I remember, File can only reference the app:// and file:// local protocols. From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of ursprakash6 Sent: Monday, February 16, 2009 11:55 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Prob with CopyTo in AIR[getting File or directory does not exist Error] Hi All I'm very new to Adobe AIR,in My sample application i'm trying to copy one image in website to local file system,i got File or directory does not exist error i have tried the below lines of code var vfile:File=new File(http://tinycomb.com/wp-content/uploads/2008/12/adobe-logo.jpg;); var dfile:File=File.applicationStorageDirectory.resolvePath(tempdata/ + video_url); vfile.copyTo(dfile, true); here i'm copying to ApplicationstorageDirestory,this would be any local direstory But i'm gtting File or directory does not exist error fot the above code. Can any one tell me whats wrong with the above code Thanks in Advance Gnanz... http://gnanz-flexworld.blogspot.com -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. image001.jpgimage002.jpg
RE: {Disarmed} [flexcoders] AIR update framework only works to update AIR file
Mike Chambers blog should be a starting point. http://www.mikechambers.com/blog/2007/11/07/detecting-whether-an-air-app lication-has-run-before/ KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of handitan Sent: Monday, February 16, 2009 8:04 AM To: flexcoders@yahoogroups.com Subject: Re: {Disarmed} [flexcoders] AIR update framework only works to update AIR file Hi KFB, Thank you for your great input. So basically for my need, I need to have a customized update system since I am dealing not just AIR file but other files as well. There are a number of references about determining whether it's the first-run or not so adaptation of those techniques is probably worth looking at. Could you please let me know where I can get these references? Thanks! --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com , Kevin Benz kb...@... wrote: You need to be aware of the two paths to update Air applications. The UI approach, one where you configure the UI of the update process through a XML file and an API approach where you take programmatic control of the update. Ultimately the goal of the UpdaterUI was to update the Air file alone (and then start it)so if you need to move files around, update SQLite or something like that, you are going to have to do what you need in Actionscript. The update framework in no-way has the capabilities of commercial installers. Can't call external processes, directly move files around, etc Since the updater mechanisms are running in the old code, not the new Air file, it can't know what needs to updated, meaning you are going to end up writing code in your app's normal bootstrap process that determines that an update has occurred and makes the necessary changes. There are a number of references about determining whether it's the first-run or not so adaptation of those techniques is probably worth looking at. In our apps, we have the current client version in the SQLite database. If the running client does not match that version number, we call whatever update process we need and on completion update SQLite to the current running client version id. KFB From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com ] On Behalf Of handitan Sent: Friday, February 13, 2009 1:02 PM To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com Subject: {Disarmed} [flexcoders] AIR update framework only works to update AIR file? Hi all, I have been reading articles about using AIR update framework. To my understanding this only works to update AIR file?? I hope I am wrong... Since my AIR app is using Flex-only swcs and is loading Flex-only modules. Anybody can shed a light on this? -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. image001.jpgimage002.jpg
Re: [flexcoders] AIR Application is not Appearing
Please be aware of a very simple issue that I don't believe is well documented... When you go through an upgrade of an existing project from SDK 3.1 to 3.2 where Air is involved, the compiler links the appropriate Air objects based on what is contained in the app.xml file (YOUR APPLICATION NAME-app.xml) in the project home directory. You will find either (the compiler usually crabs about this if you rely on objects not in the chosen library though) application xmlns=http://ns.adobe.com/air/application/1.1; or application xmlns=http://ns.adobe.com/air/application/1.5; Make sure this is set correctly for your target environment. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Douglas Knudsen Sent: Saturday, February 14, 2009 7:17 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] AIR Application is not Appearing I've seen this occur if there is some sort of startup error. ( No global exception handler, eh? ). For example, if your Air app is looking for a config file using static inatialiser on startup and can't find it, it could just hang there. Check the flashlog for errors. DK On 2/13/09, Alex Harui aha...@adobe.com mailto:aharui%40adobe.com wrote: Did they try uninstalling and re-installing? Alex Harui Flex SDK Developer Adobe Systems Inc.http://www.adobe.com/ Blog: http://blogs.adobe.com/aharui From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com ] On Behalf Of Ashish Verma Sent: Friday, February 13, 2009 7:03 AM To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com Subject: [flexcoders] AIR Application is not Appearing Hello All, I created an AIR Application which was previously based on AIR 1.0 and I am some more features in that application and compiling with the update of Flex 3 and targeting it for AIR 1.5. After making air file I am putting it onto sever to access by users. But when any user trying to run it after uploading it's not displaying any window only showing task-bar button and doing noting. When I use the task-bar context to move command I can see the dotted rectangle on the desktop. I also checked for the installation folder of the application in C:\Documents and Settings\username\Local Settings but there was no any folder for it. Please help me out. Best, Ashish -- Sent from my mobile device Douglas Knudsen http://www.cubicleman.com this is my signature, like it? -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean.
RE: {Disarmed} [flexcoders] AIR update framework only works to update AIR file?
You need to be aware of the two paths to update Air applications. The UI approach, one where you configure the UI of the update process through a XML file and an API approach where you take programmatic control of the update. Ultimately the goal of the UpdaterUI was to update the Air file alone (and then start it)so if you need to move files around, update SQLite or something like that, you are going to have to do what you need in Actionscript. The update framework in no-way has the capabilities of commercial installers. Can't call external processes, directly move files around, etc Since the updater mechanisms are running in the old code, not the new Air file, it can't know what needs to updated, meaning you are going to end up writing code in your app's normal bootstrap process that determines that an update has occurred and makes the necessary changes. There are a number of references about determining whether it's the first-run or not so adaptation of those techniques is probably worth looking at. In our apps, we have the current client version in the SQLite database. If the running client does not match that version number, we call whatever update process we need and on completion update SQLite to the current running client version id. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of handitan Sent: Friday, February 13, 2009 1:02 PM To: flexcoders@yahoogroups.com Subject: {Disarmed} [flexcoders] AIR update framework only works to update AIR file? Hi all, I have been reading articles about using AIR update framework. To my understanding this only works to update AIR file?? I hope I am wrong... Since my AIR app is using Flex-only swcs and is loading Flex-only modules. Anybody can shed a light on this? -- This message has been scanned for viruses and dangerous content by MailScanner http://www.mailscanner.info/ , and is believed to be clean. image001.jpgimage002.jpg
[flexcoders] Alchemy
I've been through the Alchemy documentation (what there is) and am wondering if anyone has made any progress with it? Mostly interested in guidelines regarding what type of project might be a good target and what might not be. For example, would a sound object that processes PCM sound data altering spectrum be a target for Alchemy? Is there a better list? KFB
RE: [flexcoders] localConnection not working from Air to Air
There is a security context that runs between Air applications that you need to make happy. Air expects to share a security token between caller and callee in order to accept the transport. As a fast-track, I would explore Arthropod to see their discussion of security integration between Air and their debugging Air app. http://arthropod.stopp.se/ K From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of luvfotography Sent: Thursday, February 05, 2009 12:05 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] localConnection not working from Air to Air Any hints on getting a localConnection to work from AIR to AIR? It works from FLEX to FLEX, I am using the code from the livedocs example. I am getting a statusEvent of 'error'. thanks, ?xml version=1.0 encoding=utf-8? mx:WindowedApplication xmlns:mx=http://www.adobe.com/2006/mxml; layout=absolute creationComplete=initConn() backgroundAlpha=0 backgroundColor=#FF mx:Script ![CDATA[ import flash.net.LocalConnection; private var conn:LocalConnection; private function initConn():void{ btnSend.addEventListener(MouseEvent.CLICK, sendMessage); conn = new LocalConnection(); conn.allowDomain('*'); conn.addEventListener(StatusEvent.STATUS, onStatus); } private function sendMessage(event:MouseEvent):void { conn.send(localConn, localconnectionHandler, inputTask.text); } private function onStatus(event:StatusEvent):void { switch (event.level) { case status: labelStatus.text = LocalConnection.send() succeeded; break; case error: labelStatus.text = LocalConnection.send() failed; break; } } ]] /mx:Script mx:Panel horizontalCenter=0 verticalCenter=0 mx:Form width=100% height=100% horizontalCenter=0 verticalCenter=0 mx:FormItem label=Enter Task mx:TextInput id=inputTask/ /mx:FormItem mx:FormItem label=Send Task mx:Button id=btnSend label=Send/ /mx:FormItem mx:ControlBar mx:Label id=labelStatus text=/ /mx:ControlBar /mx:Form /mx:Panel /mx:WindowedApplication ?xml version=1.0 encoding=utf-8? mx:WindowedApplication xmlns:mx=http://www.adobe.com/2006/mxml; layout=absolute creationComplete=InitConn() backgroundAlpha=0 width=600 height=600 backgroundColor=#FF mx:Script ![CDATA[ import flash.net.LocalConnection; private var conn:LocalConnection; private function InitConn():void{ conn = new LocalConnection(); conn.allowDomain('*'); conn.client = this; try { conn.connect(localConn); textareaTasks.text= textareaTasks.text + CONNECTING TO playlistDebug + \n; } catch (error:ArgumentError) { trace(Can't connect.); textareaTasks.text= textareaTasks.text + Can't connect. + \n; } } public function localconnectionHandler(msg:String):void { textareaTasks.text= textareaTasks.text + msg + \n; } private function clearTasks(event:MouseEvent):void { textareaTasks.text=; } ]] /mx:Script mx:Panel horizontalCenter=0 verticalCenter=0.5 verticalGap=15 paddingLeft=20 paddingRight=20 paddingBottom=20 paddingTop=20 height=100% width=100% mx:Label text=Trace output:/ mx:TextArea id=textareaTasks top=20 left=20 right=20 bottom=20 width=100% height=100%/ mx:HBox mx:Button id=btnClearTasks click=clearTasks(event) label=Clear / mx:Button id=connectagain click=InitConn( ) label=ConnectAgain / /mx:HBox /mx:Panel /mx:WindowedApplication image003.jpgimage004.jpg
RE: [flexcoders] Encrypted html
No reason why you couldn't do it locally without the web server. Open a file, decrypt it, display it, no need for http as it ultimately is a file servlet. K From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Paul Andrews Sent: Sunday, February 01, 2009 3:50 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Encrypted html In an ideal world, I'd have an AIR app displaying HTML pages sourced from encrypted data installed on the same machine. Seems to me that the only way to keep the data encrypted would be to install a web server which decrypts the pages on the fly. Am I missing a something simple? Paul image001.jpgimage002.jpg
RE: [flexcoders] Encrypted html
Certainly going to be an issue with standard HTML renderers unless you can override them and insert your own behavior to an anchor. I expect that webkit, when presented with a file://filepath file:///\\filepath , will go load that file regardless of any click-handlers running in Air. An approach would have every click, call a Javascript handler and pass in the target of that click which loads your decrypter and returning the resulting page as the calling page source. Of course, that assumes that you have control of the page content, although I assume you could load and parse the DOM regardless. I expect a JS approach might imply security issues over a dedicated web server. I've used AppWeb before to build custom http based services but that always ends up being an effort of significant complexity. K From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Paul Andrews Sent: Monday, February 02, 2009 9:40 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Encrypted html But what about the links? There will be links to other encrypted html files and I don't want to decrypt them all at once. Paul - Original Message - From: Kevin Benz mailto:kb...@passalongnetworks.com To: flexcoders@yahoogroups.com Sent: Monday, February 02, 2009 4:25 PM Subject: RE: [flexcoders] Encrypted html No reason why you couldn't do it locally without the web server. Open a file, decrypt it, display it, no need for http as it ultimately is a file servlet. K From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Paul Andrews Sent: Sunday, February 01, 2009 3:50 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Encrypted html In an ideal world, I'd have an AIR app displaying HTML pages sourced from encrypted data installed on the same machine. Seems to me that the only way to keep the data encrypted would be to install a web server which decrypts the pages on the fly. Am I missing a something simple? Paul image001.jpgimage002.jpg
RE: [flexcoders] Re: Flex Builder 3 crashes (Vista)
On Vista, I would search for other copies of that file in weird places. A synchronization folder for example. I have no experience running FlexBuilder(FB) on Vista as I prefer to avoid painful challenges where I can. Here is an idea for you (although a little off topic). We don't install the full FB IDE but rather do the follow.. It also makes FB a lot faster and reduces the memory overhead.. This may seem really strange. All of our developers install the C++ version of Eclipse 3.3.2 and then disable the C++ plug-in. Then install the FB plug-in. There is just so much goo that comes in with standard FB from Java and JDT that when you will be surprised how quickly it boots. Downside is that those who do both Java and FB end up with two installs but we try to isolate Flex developers from IDE pain so I don't let them install many plug-ins anyway. The way the MXML preview component leaks memory, you have to take whatever shortcuts you can. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Dmitri Girski Sent: Monday, January 19, 2009 2:56 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: Flex Builder 3 crashes (Vista) Hi Kevin, Thank you very much for such detailed instructions. First, I looked into the log - the exception I can see there is the following: !MESSAGE Error creating actionscript project for ui_login !STACK 1 org.eclipse.core.runtime.CoreException: Error Loading Project Then, I just recreated the new workspace and so far (2 days yet) have not got any crashes. Who-hoo! PS Do you have any idea why FlexBuilder.ini is ignored under Vista? Cheers, Dmitri. --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com , Kevin Benz kb...@... wrote: Been there, done that. OK.. There are two paths for you. Eclipse Errors: Eclipse makes mountains of log entries so you need to isolate Flex issues from Eclipse Issues. Go through the eclipse logs looking for errant components and Null Pointer Exceptions. Although the openness of eclipse encourages the addition of all kinds of great and not so great components (Java, Maven, Data Tools, JDT), I believe strongly that the Flex development environment should be sandboxed and kept single purpose. Yes, I have two eclipse installs. Flex: Flex issues like this, we have found to be resultant to the operation of Flex and the operation of SCM and SDK upgrades. I see you are using 3.0.2 which tells me your recently updated to the 3.2 SDK. I am convinced that Flex cannot handle an SDK upgrade well. Let me explain. We have a very large project that started during SDK 3.0 with the project files being checked into Subversion as 3.0 files. Now there are lots of argument regarding checking in project files as in most cases they can become platform and developer specific, after going to the 3.1 SDK we lost the ability to use the compiler options tab in the project properties window with Flex complaining about the SDK string value. After a few minutes the IDE becomes unstable and crashes. No matter what we did, we could not recover (copy files around between developers, manually fixup the SDK and locale strings). If you checked out your project again, you have project files built for a different SDK. In over for us to overcome this, here is what we do. 1. BACKUP EVERYTHING 2. Turn off automatic build 3. Find all instances of files with the .cache extension within the Flex plug-in directories THAT START WITH YOUR PROJECT NAME (for example myproject.cache) and remove them. They automatically come back when the compiler runs. 4. Use FlexBuilder to create a new Empty Workspace. Leave the old one alone if we need to get back to it. WE DO NOT MAKE ANY CHANGES TO THE OLD WORKSPACE 5. In FlexBuilder, create new copies of the project(s) in the new workspace USING THE EXACT NAMES OF THE PRESENT PROJECTS. Leaving these projects empty, in their initial state. This will create new project files with the correct SDK string, locale, etc etc. 6. Backup these new projects from the new workspace and put them aside. 7. If using SCM, checkout the project(s) into the new workspace OR if not using SCM, copy OLD project(s) into the new workspace directory. THIS IS IMPORTANT AS YOU CANNOT RELIABLY MOVE A FOLDER UNDER SCM AND HAVE IT WORK. IT SHOULD BE CHECKED OUT AGAIN. 8. From your new workspace, recently checked out or copied, remove the following files .project .actionSciptProperties .flexProperties /.settings/org.eclipse.core.resources.prefs 9. Copy the empty versions of these files (that were put aside) into the new workspace. 10. Start FlexBuilder and on each project's properties, enter the Library Build Path, on the classes tab and uncheck /src and save/close that form. THEN go back in and check that checkbox, close (this forces Flexbuilder to walk the filesystem and update its catalog of local
RE: [flexcoders] Flex Builder 3 crashes (Vista)
Been there, done that. OK.. There are two paths for you. Eclipse Errors: Eclipse makes mountains of log entries so you need to isolate Flex issues from Eclipse Issues. Go through the eclipse logs looking for errant components and Null Pointer Exceptions. Although the openness of eclipse encourages the addition of all kinds of great and not so great components (Java, Maven, Data Tools, JDT), I believe strongly that the Flex development environment should be sandboxed and kept single purpose. Yes, I have two eclipse installs. Flex: Flex issues like this, we have found to be resultant to the operation of Flex and the operation of SCM and SDK upgrades. I see you are using 3.0.2 which tells me your recently updated to the 3.2 SDK. I am convinced that Flex cannot handle an SDK upgrade well. Let me explain. We have a very large project that started during SDK 3.0 with the project files being checked into Subversion as 3.0 files. Now there are lots of argument regarding checking in project files as in most cases they can become platform and developer specific, after going to the 3.1 SDK we lost the ability to use the compiler options tab in the project properties window with Flex complaining about the SDK string value. After a few minutes the IDE becomes unstable and crashes. No matter what we did, we could not recover (copy files around between developers, manually fixup the SDK and locale strings). If you checked out your project again, you have project files built for a different SDK. In over for us to overcome this, here is what we do. 1. BACKUP EVERYTHING 2. Turn off automatic build 3. Find all instances of files with the .cache extension within the Flex plug-in directories THAT START WITH YOUR PROJECT NAME (for example myproject.cache) and remove them. They automatically come back when the compiler runs. 4. Use FlexBuilder to create a new Empty Workspace. Leave the old one alone if we need to get back to it. WE DO NOT MAKE ANY CHANGES TO THE OLD WORKSPACE 5. In FlexBuilder, create new copies of the project(s) in the new workspace USING THE EXACT NAMES OF THE PRESENT PROJECTS. Leaving these projects empty, in their initial state. This will create new project files with the correct SDK string, locale, etc etc. 6. Backup these new projects from the new workspace and put them aside. 7. If using SCM, checkout the project(s) into the new workspace OR if not using SCM, copy OLD project(s) into the new workspace directory. THIS IS IMPORTANT AS YOU CANNOT RELIABLY MOVE A FOLDER UNDER SCM AND HAVE IT WORK. IT SHOULD BE CHECKED OUT AGAIN. 8. From your new workspace, recently checked out or copied, remove the following files .project .actionSciptProperties .flexProperties /.settings/org.eclipse.core.resources.prefs 9. Copy the empty versions of these files (that were put aside) into the new workspace. 10. Start FlexBuilder and on each project's properties, enter the Library Build Path, on the classes tab and uncheck /src and save/close that form. THEN go back in and check that checkbox, close (this forces Flexbuilder to walk the filesystem and update its catalog of local classes) and save that form. You are basically faking an import 11. Back in Library Build Path, the project may need any swc's or referenced projects that were in the old project configuration. 12. Turn back on automatic build. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Dmitri Girski Sent: Saturday, January 17, 2009 6:38 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Flex Builder 3 crashes (Vista) Hi everybody, After some absolutely painless 6 months run, my Flex Builder 3 (3.0.2) started to crash every 10-15 minutes under Vista (I know, I know, this is beyond my control, I have to live with this). The only one thing which actually changed is Flash CS4 - all components have been recompiled using Flash CS4 for FP9. There is some difference as these components now visible all the time in the Design View. SWCs compiled with Flash CS3 were very freaky in Design View. Here is the Java Screen Of Death: http://mitek.id.au/flex/builder_crash.jpg A couple of questions: 1. Why Xmx Xms parameters are repeated twice (see the screenshot)? 2. Why Flex Builder simply ignores C:\Program Files\Adobe\Flex Builder 3\FlexBuilder.ini file? I can place any values and parameters there and it just ignores them. 3. Why does it happen and who is responsible? (this question is rhetorical) If anyone had this problem before please share your experience. Thanks in advance. Cheers, Dmitri. image001.jpgimage002.jpg
RE: [flexcoders] Re: LocalConnection issue in AIR to AIR application
So if I understand you, this is the calling (outbound side of the request) and this error is in the console output? Phase 2 means that it was in the targeting phase of the dispatch. Are you calling allowDomain() on the connection object? From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Pete Appleby Sent: Thursday, January 15, 2009 4:49 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: LocalConnection issue in AIR to AIR application Hi, Kevin. Thanks for the pointer. I looked at the example in the arthropod debugger class. Unfortunately, it is only the send half of the equation. It did point me into the direction of verifying that the domain name is correct. The error I receive from the Send status event is: type=status bubbles=false cancelable=false eventPhase=2 code=null level=error There is not much to go with. My test sample applications display the names used in the Connect and Send, everything seems to be in order. Not sure how I can post code here. A google search found only a few hits on the above error. One was the same post a few times about using in FLASH when the receiving swf file was not running. Another was in German, and my high school German was over 30 years ago. Any ideas about this are appreciated! Pete image001.jpgimage002.jpg
RE: [flexcoders] Re: LocalConnection issue in AIR to AIR application
And one other important note. The ADL runtime (the debug player) needs special handling in order for enable communication to happen. You need to set command-line arguments to make it work with Air to Air communication work. Note: When you run your application with ADL (or with a development tool such as Flash CS3, Flex Builder, or Dreamweaver), the publisher ID is null and must be omitted from the domain string. When you install and run your application, the publisher ID must be included in the domain string. You can assign a temporary publisher ID using the ADL command line arguments. Use a temporary publisher ID to test that the connection string and domain name are properly formatted. adl [-runtime runtime-directory] [-pubid publisher-id] [-nodebug] application.xml [root-directory] [-- arguments] -pubid publisher-id Assigns the specified value as the publisher ID of the AIR application for this run. Specifying a temporary publisher ID allows you to test features of an AIR application, such as communicating over a local connection, that use the publisher ID to help uniquely identify an application. The final publisher ID is determined by the digital certificate used to sign the AIR installation file. Better yet, export your Air runtimes and try without the adl fun. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Pete Appleby Sent: Thursday, January 15, 2009 4:49 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: LocalConnection issue in AIR to AIR application Hi, Kevin. Thanks for the pointer. I looked at the example in the arthropod debugger class. Unfortunately, it is only the send half of the equation. It did point me into the direction of verifying that the domain name is correct. The error I receive from the Send status event is: type=status bubbles=false cancelable=false eventPhase=2 code=null level=error There is not much to go with. My test sample applications display the names used in the Connect and Send, everything seems to be in order. Not sure how I can post code here. A google search found only a few hits on the above error. One was the same post a few times about using in FLASH when the receiving swf file was not running. Another was in German, and my high school German was over 30 years ago. Any ideas about this are appreciated! Pete image001.jpgimage002.jpg
RE: [flexcoders] LocalConnection issue in AIR to AIR application
Have you looked to see how Arthropod does it? There is a unique identifier that is shared between Air apps to allow them to interact. http://arthropod.stopp.se/ KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Pete Appleby Sent: Thursday, January 15, 2009 1:07 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] LocalConnection issue in AIR to AIR application Hi, all. I am attempting to get started with two AIR applications talking to each other. Unfortunately, the StatusEvent basically just says error in the event.level after the Send request. How do I go about debugging this? I am not getting any Security or Async errors from the send. Where can I dig deeper into this? Thanks! Pete image001.jpgimage002.jpg
RE: [flexcoders] Re: AIR and SQLLite
If you don't have to preserve any existing client data, then you could simply rip and replace the existing db file. Your Air application could drop the file, back it up or whatever and then replace it with another copy downloaded from a server. If you need to preserve some of the data then your problem becomes much more daunting. First you need to determine the rules by which an update is to occur. Is it at application start or part of some predefined schedule? What happens if one user leaves their client up for days/weeks/months and another restarts hourly? If you base on application start, how will you insure that you cover both use cases? How will you insure that client A and client B don't have different data? I would suggest adding timestamps to every server synchronized row allowing you to implement some concept of knowing what data might be stale. K From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of bonny_us Sent: Tuesday, January 13, 2009 7:02 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: AIR and SQLLite Hi Kevin, i want to do synchronize all client sqlite db's from a common back-end db? Thanks, Bonny --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com , Kevin Benz kb...@... wrote: What are you asking? Are you wanting to synchronize all client sqlite db's from a common back-end db? Are you wanting to replicate the client data on the server? Air doesn't provide any facilities to help with either although both could be accomplished with a non-trivial development effort. I know there is some discussion on the web of tools to help although you need to be aware of the fact that Adobe extended SQLite with support for AS datatypes (like Date for example) so beware of tools that may not be aware of your whole schema. K From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com ] On Behalf Of bonny_us Sent: Monday, January 12, 2009 7:57 PM To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com Subject: [flexcoders] AIR and SQLLite Hi All, Any one have idea of SQLLite and AIR Synchronization. I want to create one POC using SQLLite. If any one have any example regarding this then please let me know. it will be very helpful to me. Thanks, Bonny image001.jpgimage002.jpg
RE: [flexcoders] AIR and SQLLite
What are you asking? Are you wanting to synchronize all client sqlite db's from a common back-end db? Are you wanting to replicate the client data on the server? Air doesn't provide any facilities to help with either although both could be accomplished with a non-trivial development effort. I know there is some discussion on the web of tools to help although you need to be aware of the fact that Adobe extended SQLite with support for AS datatypes (like Date for example) so beware of tools that may not be aware of your whole schema. K From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of bonny_us Sent: Monday, January 12, 2009 7:57 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] AIR and SQLLite Hi All, Any one have idea of SQLLite and AIR Synchronization. I want to create one POC using SQLLite. If any one have any example regarding this then please let me know. it will be very helpful to me. Thanks, Bonny image001.jpgimage002.jpg
RE: [flexcoders] Creating Asynchronous Classes
We use MD5 and understand the issue completely. We use classes that look at the file a chunk at a time as we don't want to load 60+MB MP4 files into a ByteArray. Our solution did help in keeping the general memory overhead under control. The issue becomes one of time as although our Air client can usually bring a large file down in a reasonable amount of time (let's say 1-3 or so minutes for a broadband connection) the sticky point is the MD5 typically ate another 2+ minutes to complete. Likewise hoping to implement a progress indicator, MD5 (or any CRC like mechanism) is processor heavy leaving you with the challenge the balance of running an animation at the same time you want your processor to be handling your check with the more animation, the slower your CRC will be. If your mention of Asynchronous means you want this to run on its own thread, then you need to realize that the Flash Player is single threaded (but read about HTTP traffic). KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of nathanpdaniel Sent: Friday, January 02, 2009 2:03 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Creating Asynchronous Classes Is there a primer on creating asynchronous classes? I've been building an app that runs a CRC32 check on each file (which requires looking at every byte of every file). It doesn't cause issues when the files are small text files, but when they're 40mb video files, the app hangs till complete. I want the app to be able to update other things while waiting on the CRC32 functionality completes. Actually, all I need is some visual progress indicator (some way to update the display). Anyone with any suggestions! I'm all ears! :D -N. D. image001.jpgimage002.jpg
RE: [flexcoders] Any Developers on a Mac?
Speaking for my organization, we have a team with both platforms as well as a number who run Mac's in a virtualized environment with Flex on both the Mac and PC sides. Speaking for us, I can say the biggest single issue we have is the fact that project files get checked in. Although the project files work equally on both platforms, what really gums up the works is going thru Flex upgrade, for example SDK 3.0 to SDK 3.1, can be a big headache. Don't get me wrong, checking in project files can provide a significant productivity gain as getting developers up to speed in a common development environment is a big help. When the SDK string, in the .actionScriptProperties gets parsed to point to either an SDK that isn't there anymore or its identity has changed, you will get to the point where the project properties can no longer be viewed or modified. We has seen this cause workspace and compiler errors as well. The only reasonable workaround to this condition is to create new empty projects, move those new project files aside, checkout your project and then restore those newly created project files and then go through the process of manually setting up your projects. So you ask yourself, why not just check-in updated project files? Certainly a solution however there are a number of reasons why I choose to avoid that. The project files carry with them asset and class bindings that may or may not be appropriate for each developer to automatically inherit. KFB From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Ralf Bokelberg Sent: Tuesday, December 30, 2008 11:43 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] Any Developers on a Mac? I wonder if people see problems with teams of Mac Windows machines? We sometimes see some problems, and i wonder if the problem comes from a Mac user, who joined our Team lately. We share some of our Workspace settings via SubVersion. We don't use absolute pathes in our settings though. Cheers Ralf. On Tue, Dec 30, 2008 at 7:51 PM, Cole Joplin cole_jop...@yahoo.com mailto:cole_joplin%40yahoo.com wrote: What is better or worse is a matter of opinion, I think. I have used FB on Windows and Mac, and it really doesn't matter. I've switched to the Mac, as a developer, fulltime, and I'm having no problems, it's solid. It seems to me that the biggest problems people have are more about which version of the library/player/AIR they are using than FB. I say choose the OS you like, and get Flex, FB or not. You're not getting dinged here. Personally, I'd choose the Mac in a heartbeat. From: Jim Hayes j...@primalpictures.com mailto:jim%40primalpictures.com To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com Sent: Monday, December 29, 2008 4:04:20 AM Subject: RE: [flexcoders] Any Developers on a Mac? General platform discussions aside, what is it that makes flexbuilder slightly worse on mac than it is in windows? I'm considering trying out a macbook pro as my next laptop (been on windows, sometimes linux, for past ten years or so), but most of my work is in flexbuilder these days so it would be nice to know. Many thanks! -Original Message- From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com ] On Behalf Of Josh McDonald Sent: 29 December 2008 10:44 To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com Subject: Re: [flexcoders] Any Developers on a Mac? Kevlar suit... *check*! It's good. I'm happy with it, many people are. I think it's much better, many people agree. And many *other* people here will call me a big girl for thinking so. Which I find hilarious. But this is a well-abused topic here. Builder is slightly better in Windows. in my opinion everything else is better on Mac :) -Josh On Mon, Dec 29, 2008 at 8:24 PM, composerguru kbmulvihill@ gmail.com wrote: I'm thinking of converting now that I've dumped Vista... just wondering what your experience might be and if you recommend the change? Thanks in advance, Kevin - - -- -- Flexcoders Mailing List FAQ: http://groups. yahoo.com/ group/flexcoders /files/flexcoder sFAQ.txt Alternative FAQ location: https://share. acrobat.com/ adc/document. do?docid= 942dbdc8- e469-446f- b4cf-1e62079f684 7 Search Archives: http://www.mail- archive.com/ flexcoders% 40yahoogroups. comYahoo! Groups Links -- Therefore, send not to know For whom the bell tolls. It tolls for thee. Like the cut of my jib? Check out my Flex blog! :: Josh 'G-Funk' McDonald :: 0437 221 380 :: j...@gfunk007. com :: http://flex. joshmcdonald. info/ :: http://twitter. com/sophistifunk __ This communication is from Primal Pictures Ltd., a company registered in England and Wales with
RE: [flexcoders] Pattern for capturing multi-key/click actions?
Two and three key sequences private var _escIsDown:Boolean=false; private var _f1IsDown:Boolean=false; private var _f2IsDown:Boolean=false; private var _f4IsDown:Boolean=false; private function onKeyStrokeEvent(event:KeyboardEvent):void { if(event.keyCode==Keyboard.ESCAPE) { this._escIsDown = (event.type == KeyboardEvent.KEY_DOWN); } if(event.keyCode==Keyboard.F1) { this._f1IsDown = (event.type == KeyboardEvent.KEY_DOWN); } if(event.keyCode==Keyboard.F2) { this._f2IsDown = (event.type == KeyboardEvent.KEY_DOWN); } if(event.keyCode==Keyboard.F4) { this._f4IsDown = (event.type == KeyboardEvent.KEY_DOWN); } if(this._escIsDown this._f1IsDown this._f4IsDown ){ this.panicFunction(); } if(this._escIsDown this._f2IsDown ){ this.callHome(); } } /** * place code in this function to be executed by client when instructed by support. * */ private function callHome():void { DoSomething(); trace(CALL HOME FUNCTION CALLED: ); } /** * place code in this function to be executed by client when instructed by support. * */ private function panicFunction():void { DoSomethingElse(); trace(PANIC FUNCTION CALLED: ); } From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of mookie298347 Sent: Tuesday, December 16, 2008 10:47 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Pattern for capturing multi-key/click actions? I would like to add multi-key/click functionality to my Flex app. There are a couple of slightly different examples of what I mean: 1. Detect when a user is holding down the 'r' key while clicking a button. 2. Detect when a certain component has focus and the user types the letters 'd' 's' in succession within a few seconds of each other. I noticed there are properties in the MouseEvent class to detect things like shift,ctrl and alt keys but I need to detect more than just those. Additionally those properties don't exist in other event classes like ItemClickEvent. What I have done so far is simply create a state object at the application level that captures all keyboard/mouse events and sets the state of itself based on the events. Individual components can check the current state at any time to determine which keys/mouse actions are currently active. I don't particularly like this implementation for many reasons and was hoping someone knew of a pattern to use considering many applications support such functionality (Eclipse comes to mind). Thanks! image001.jpgimage002.jpg
RE: [flexcoders] Upload file(from local machine) via web service
Depends on what you mean by support and what you are actually trying to do. Can I assume you are talking about an AIR application (as you are referring to the FileReference class). Is there a canned function that takes a file reference and uploads it to a server? No Is there a HTTP client allowing you to create almost anything? Certainly. First, a file reference is simply a reference to the file. You will need call the upload method on that reference and pass it a valid URLRequest object. For our organization, we choose not call web services with binary data uploads but rather use multi-part forms to perform the upload of images and other complex objects. If your plan is to load the file and post the contents of that file more along the lines of REST, then you can easily get to the data of the FileReference and post that as well however pay attention to the necessities of encoding the payload. See this - http://blog.flexexamples.com/2007/10/30/using-for-the-filereference-clas ss-uploadcompletedata-event-to-capture-data-from-a-server-side-script Also, explore googlecode especially the flickr actionsript API's but we aware of the fact that if you are going to have to deal with binaries as well as large file, you will probably be building out your own solution. The Flickr API's are pretty specific (obviously) and implement their server side generic method invoking pattern. You should be able to see how HTTP works. K From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Amanda Sent: Thursday, October 23, 2008 6:48 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Upload file(from local machine) via web service Hi, Does anyone know if flex supports browsing a local file system for a file and then sending the file via a web service? I have seen the flash.net.FileReference class, but I am not seeing a way to convert the fileReference to something useful like an XMLDocument so I can send it. Thanks. Amanda S. image001.jpgimage002.jpg
RE: [flexcoders] FZip loads cached zip before downloading online
Not sure exactly what is happening but I suggest an improvement to your approach. You should detect the change in network connection status and use that event to flush any objects that are waiting on an event to fire. AIR fires a NETWORK_CHANGED event and I would make sure you clean up your objects at that point. You cannot depend on the quality of the bits you just downloaded regardless and need to re-enter the process. KFB From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of diigiibot Sent: Friday, October 17, 2008 3:31 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] FZip loads cached zip before downloading online I'm using FZip in an AIR application, the application loads the zip from a location on our server, unpacks the zip and move the files to their local folder. Everything runs smooth until I cut off my internet connection while the zip is downloading. When I restart the application it looks like FZip is first checking the temp folder for the cached zip and if found, it uses that one to unzip, even if the zip was not completed the last time. Does anyone know of a way to prevent that? I use the default load method of the FZip library, this is a part of the code I use. var moduleLink:String = [EMAIL PROTECTED]; var zip:FZip = new FZip(); zip.addEventListener(Event.COMPLETE, onComplete); zip.load(new URLRequest(moduleLink)); private function onComplete(evt:Event):void { var moduleDir:File = File.applicationStorageDirectory.resolvePath(modules); var outStream:FileStream; for(var i:int; ievt.target.getFileCount();i++) { var zipFile:FZipFile = evt.target.getFileAt(i); if(zipFile.sizeUncompressed == 0 zipFile.filename.toString().substr(-1) == /) { var rootDir:File = File.applicationStorageDirectory.resolvePath(modules/+zipFile.filename .toString()); } else { var tempFile:File = moduleDir.resolvePath(zipFile.filename); outStream = new FileStream(); outStream.open(tempFile, FileMode.WRITE); outStream.writeBytes(zipFile.content, 0, zipFile.sizeUncompressed); outStream.close(); } } evt.target.close(); } Thanks in advance
RE: [flexcoders] Re: Flex uploader / accessing local files?
This actually isn't very tough at all. You need to get the File object, load its BitmapData and use the Matrix object to size it and then either PNGEncode or JPGEncode back out. From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of valdhor Sent: Friday, October 17, 2008 6:41 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: Flex uploader / accessing local files? It looks like you'll have to wait for Flash Player 10. See this thread: http://tech.groups.yahoo.com/group/flexcoders/message/126563 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com , Rob Kunkle [EMAIL PROTECTED] wrote: Hi - I've made a flex uploading application that gets a file from the client's file system using FileReference() and uploads it to a server. I'd like to be able to resize the image before it is sent to the server, but apparently flex doesn't have access to the actual bits that make up the image file, only a reference to the file. Surely there must be a way to manipulate that image data from the client's file before it gets to the server? Has anyone done anything like this? I've looked all around but haven't had much luck. Thanks in advance, Rob image001.jpgimage002.jpg
RE: [flexcoders] Re: FZip loads cached zip before downloading online
When you destroy the FZip object, don't necessarily know and if you don't know, you have to clean up after yourself. Remember, when you use HTTP, you are subject to timeouts that may or may not expire as you expect them let alone the myriad of other errors along the way (permissions, server error, etc). If you only wait for a Complete event, then the HTTP object is left hanging and the file is certainly in a dirty state as well. K From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of diigiibot Sent: Friday, October 17, 2008 9:09 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: FZip loads cached zip before downloading online Yes, that could be a solution. I'll try it out. Only I'm not sure the partially downloaded zip will be removed from the temp folder when I remove the FZip object. --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com , Kevin Benz [EMAIL PROTECTED] wrote: Not sure exactly what is happening but I suggest an improvement to your approach. You should detect the change in network connection status and use that event to flush any objects that are waiting on an event to fire. AIR fires a NETWORK_CHANGED event and I would make sure you clean up your objects at that point. You cannot depend on the quality of the bits you just downloaded regardless and need to re-enter the process. KFB From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com ] On Behalf Of diigiibot Sent: Friday, October 17, 2008 3:31 AM To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com Subject: [flexcoders] FZip loads cached zip before downloading online I'm using FZip in an AIR application, the application loads the zip from a location on our server, unpacks the zip and move the files to their local folder. Everything runs smooth until I cut off my internet connection while the zip is downloading. When I restart the application it looks like FZip is first checking the temp folder for the cached zip and if found, it uses that one to unzip, even if the zip was not completed the last time. Does anyone know of a way to prevent that? I use the default load method of the FZip library, this is a part of the code I use. var moduleLink:String = [EMAIL PROTECTED]; var zip:FZip = new FZip(); zip.addEventListener(Event.COMPLETE, onComplete); zip.load(new URLRequest(moduleLink)); private function onComplete(evt:Event):void { var moduleDir:File = File.applicationStorageDirectory.resolvePath(modules); var outStream:FileStream; for(var i:int; ievt.target.getFileCount();i++) { var zipFile:FZipFile = evt.target.getFileAt(i); if(zipFile.sizeUncompressed == 0 zipFile.filename.toString().substr(-1) == /) { var rootDir:File = File.applicationStorageDirectory.resolvePath(modules/+zipFile.filename .toString()); } else { var tempFile:File = moduleDir.resolvePath(zipFile.filename); outStream = new FileStream(); outStream.open(tempFile, FileMode.WRITE); outStream.writeBytes(zipFile.content, 0, zipFile.sizeUncompressed); outStream.close(); } } evt.target.close(); } Thanks in advance image001.jpgimage002.jpg
RE: [flexcoders] Can AIR call local DLLs?
The basic answer, anointed by Adobe, no.. There is no COM bridge in Air, and I don't expect there to be one either. Of note: http://www.mikechambers.com/blog/2008/01/17/commandproxy-net-air-integra tion-proof-of-concept/ another approach http://www.merapiproject.net/ Although that's a java bridge K From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of thegators_2002 Sent: Wednesday, October 15, 2008 8:26 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Can AIR call local DLLs? I have a couple older Flash 8 apps that are wrapped inside Zinc, and that call a custom DLL I did that takes some XML output from the Flash and blends it with an XML report template to spit out a PDF. I have some new applications to do, converting Flex web apps to AIR. But I need to print PDF reports for them as well. For AIR, is there any way that I can use the same custom print DLLs I have already written? I don't want to write these reports in Flex, they are really long and complex, and it would be a bad idea to have two versions to maintain along with the web-based versions. I just upgraded to Flex 3, but haven't seen this exact issue dealt with - printing to a PDF using some sort of external report template, rather than writing it out inside Flex. Thanks! image001.jpgimage002.jpg
RE: [flexcoders] Odd message on export of release build of AIR app
I believe what you are seeing is an issue with FlexBuilder where the list of classes in the Library Build Path includes a reference to the missing class. We see this mostly when we use either SubClipse or Subversive dealing with the Asset List. They basically trigger a build before all the project assets are in place corrupting (in the Java sense) the manifest or those who check in the project files (.project .flexproperties .actionscriptproperties) causing platform specific issues. Basically these lists get incrementally updated during the development lifecycle and never get completely refreshed until someone goes to the Library Build Path (Project-Properties-Library Build Path) and touches the list. This UI is used to determine what classes to make active in the project so if you are using it this way, then you will need to track what should be linked in and what shouldn't. Most though, that I am aware of, don't use the Build Path this way so the brute force fix is to uncheck all the classes, close the form, re-open the form, choose all classes and save. If you manually bind and unbind classes, then you will need to uncheck one class, close the form, open the form, recheck that class and then re-validate your list of excluded classes. KFB From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Andrew Wetmore Sent: Wednesday, October 01, 2008 2:13 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Odd message on export of release build of AIR app Hi: For the last few weeks when I export a release build of the current project, i get this error message: Flex Builder could not publish the project source: The application file courseDevClient336.mxml was not found.. The referenced file, courseDevClient336.mxml, was an artifact of a Subversion update conflict, and has never formed a part of the project. I don't know where the build process is finding the request to use it, and therefore I don't know how to address the issue. Any ideas about how I can get rid of this warning? image001.jpgimage002.jpg
RE: [flexcoders] AS3 within eclipse with Flex SDK
Tell them to buy the software. How many developer hours are excessively consumed without an integrated debugger, profiler, etc... How much does that cost? From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of gabriela.perry Sent: Wednesday, October 01, 2008 4:56 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] AS3 within eclipse with Flex SDK Hello. I'm starting a project in a client who doesnt have either Flex builder or Flex plugin. They've been working with java (myEclipse) for some time, and didnt buy anything for Flex development... I found lots of directions on how to set up Eclipse for the Flex SDK (not a difficult thing to do), but found no support for AS3... I found ASDT, but it's only for AS2... How do you guys manage this situation? Thanx in advance :0) Gabi image001.jpgimage002.jpg
RE: [flexcoders] REST Library for Flex or ActionScript?
There are a couple but none are comprehensive. The ones of note are - Flickr actionscript API's on google which are nice if you need to see both the API and a number of comprehensive ways they are used. I would rate them ok: - Arc90restlib - is more of a pattern then a nitty-gritty REST library. Ultimately we didn't use either as we are proponents of a strong factory pattern as well as the fact that we use REST in order to interact nicely with our load balancers/caching servers and we needed a strong multi-part form binary upload capability. We ended up writing our own REST implementation. You have to also remember in the AMF/FDS world you get some native error handling since the technologies on either end can be aware of each others that you have to build yourself in REST. The biggest word of caution using any external API set is to evaluate error handling as a majority of library distributions focus on the Happy Path and either ignore or gloss over when things go poorly. It really doesn't give your application a chance to gracefully recover if the only error you get back is Oh Crap. HTTP by nature empowers the application to respond differently to the range of HTTP errors it generates so with a REST library, it's your responsibility to account for a permissions issue differently than a server error. KFB From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of bryancostanich Sent: Wednesday, September 03, 2008 8:35 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] REST Library for Flex or ActionScript? Anyone know of a good REST library for AS3? I've done some research and come up empty. on cursory research, i'm not even sure it's possible to do it properly e.g.: http://www.atnan.com/2007/6/11/can-as3-do-rest-or-not anyone?
[flexcoders] Anybody found a workaround for this compiler bug?
This is sapping our productivity and wondered if anybody had seen this or had any ideas? I certainly see the association with Font rendering as the obvious first instinct would be to question the font file however with two machines seeing the same behavior, a wider look seems appropriate. There is Away3D in the project and we do take the TVNord font and render the SVG in order to support text overlaying on a 3D plane. Since the Clean always resolves the issue, I doubt that the base font file is the issue. We currently see this on 2 developer workstations, one a Mac, one a PC. The only way to get around this is to clean all the projects in the Workspace (this is part of an application where we have an Air project and 3 support library projects. Doing a Clean of the Workspace allows us to get past this (until you need to build again). KFB The problem is documented in the Adobe Bug System FB-13828. !ENTRY com.adobe.flexbuilder.project 4 43 2008-08-20 10:27:29.608 !MESSAGE Uncaught exception in compiler !STACK 0 java.lang.ArrayIndexOutOfBoundsException: 0 at flash.fonts.DefineFontFace.init(DefineFontFace.java:40) at flash.fonts.CachedFontManager.loadDefineFont(CachedFontManager.java:122) at flex2.compiler.PersistenceStore.readAssets(PersistenceStore.java:1777) at flex2.compiler.PersistenceStore.readCompilationUnit(PersistenceStore.jav a:1687) at flex2.compiler.PersistenceStore.readCompilationUnits(PersistenceStore.ja va:1372) at flex2.compiler.PersistenceStore.read(PersistenceStore.java:803) at flex2.compiler.API.loadCompilationUnits(API.java:4161) at flex2.tools.oem.Application.loadCompilationUnits(Application.java:582) at flex2.tools.oem.Application.recompile(Application.java:935) at flex2.tools.oem.Application.compile(Application.java:636) at flex2.tools.flexbuilder.BuilderApplication.compile(BuilderApplication.ja va:354) at com.adobe.flexbuilder.multisdk.compiler.internal.ASApplicationBuilder$My Builder.mybuild(ASApplicationBuilder.java:271) at com.adobe.flexbuilder.multisdk.compiler.internal.ASApplicationBuilder.bu ild(ASApplicationBuilder.java:122) at com.adobe.flexbuilder.multisdk.compiler.internal.ASBuilder.build(ASBuild er.java:139) at com.adobe.flexbuilder.multisdk.compiler.internal.ASItemBuilder.build(ASI temBuilder.java:73) at com.adobe.flexbuilder.project.compiler.internal.FlexProjectBuilder.build Item(Unknown Source) at com.adobe.flexbuilder.project.compiler.internal.FlexProjectBuilder.build (Unknown Source) at com.adobe.flexbuilder.project.compiler.internal.FlexIncrementalBuilder.b uild(Unknown Source) at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:62 4) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.ja va:166) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.ja va:197) at org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:24 6) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.ja va:249) at org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManage r.java:302) at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:33 4) at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java: 137) at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:235) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
RE: [flexcoders] Save Object with EncryptedLocalStore
Nope.. Strings only although why not XML as a string? Be careful as well... .10mb max storage although that's a lot of xml. K From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of markflex2007 Sent: Tuesday, August 26, 2008 12:53 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Save Object with EncryptedLocalStore Hi, I am working for a AIR application now. It see I only can save string with EncryptedLocalStore. But I want to save object with EncryptedLocalStore. For instance: var obj:userVO = new userVO(); obj.firstName = Tom; obj.lastName = Smith; Do you think if it is possible for me to do this? Thanks Mark image001.jpgimage002.jpg
RE: [flexcoders] Re: How to check a table already exist in SQLite?
Execute a query and see if the table name exists in the sqlite_master table. From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Tim Rowe Sent: Monday, August 25, 2008 5:10 PM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Re: How to check a table already exist in SQLite? If you only want this for when you're actually creating the table, rather than trying to confirm it exists: From http://www.sqlite.org/lang_createtable.html CREATE [TEMP | TEMPORARY] TABLE [IF NOT EXISTS] [database-name .] table-name ( column-def [, column-def]* [, constraint]* ) From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of markflex2007 Sent: Tuesday, 26 August 2008 4:54 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: How to check a table already exist in SQLite? Thanks for your help. I want to know if SQLConnection provide a method to check if a table already exist or not. Thanks Mark image001.jpgimage002.jpg
RE: [flexcoders] Date type in AIR application?
Adobe did add support for dates in SQLite, see excerpt below. The problem is most third party applications that support SQLite don't understand it so you will have limited ability to work with them, for example in the Firefox SQLite Extension For precision and for wider access to the database beyond Flex, we typically convert the date to its serial value and store that. It is highly portable and allows you to interact with it nicely. (although you have to do the conversin back obviously). Additional SQL features The following column affinity types are not supported by default in SQLite, but are supported in Adobe AIR: STRING: corresponding to the String class (equivalent to the TEXT column affinity). NUMBER: corresponding to the Number class (equivalent to the REAL column affinity). BOOLEAN: corresponding to the Boolean class. DATE: corresponding to the Date class. XML: corresponding to the ActionScript (E4X) XML class. XMLLIST: corresponding to the ActionScript (E4X) XMLList class. OBJECT: corresponding to the Object class or any subclass that can be serialized and deserialized using AMF3 (which includes most classes including custom classes, but excludes some classes including display objects and objects that include display objects as properties). From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of markflex2007 Sent: Wednesday, August 20, 2008 10:27 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Date type in AIR application? Hi, It seems SQLite doesn't have Date type. I am working in a AIR application now. I want to know how to save data with Date type to SQLite and how to read it from SQLite and convert to actionscript date type data. Do you have a simple demo? Thanks Mark image001.jpgimage002.jpg
RE: [flexcoders] Question for AIR Application?
Good luck.. I suggest looking at Mike Chambers Post http://www.mikechambers.com/blog/2008/01/17/commandproxy-net-air-integra tion-proof-of-concept/ regarding the CommandProxy concept. It's interesting reading along with his conclusions. I would almost think the Mac piece might be a little easier as you have some expectation that Java is there and can get at least some leverage from that. We are dealing with a somewhat similar requirement and have a few ideas in the lab now but nothing definitive. One other technology to track is Merapi http://merapiproject.net/ which is communicated as an Air to Java bridge. K From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of markflex2007 Sent: Wednesday, August 20, 2008 9:58 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Question for AIR Application? Hi, I want to make sure if AIR can load local application and execute it. Thanks Mark image001.jpgimage002.jpg