Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 08-27-2008, 01:25 PM   #1
bmh
Senior Member
 
bmh's Avatar
 
Join Date: Feb 2005
Location: Peterborough, NH USA
Posts: 117
Default Flash components vs. Flex components

I know almost nothing about Flex. Just wanted to establish that at the outset.

A client sent me an API component - an swc file - to use in a project I'm doing. I installed it in my Flash folders, but it didn't show up in the Components panel when I launched Flash. When I queried the client about it, he said that it was actually a Flex component.

My question is, what's the difference between a Component written for Flex and one written for Flash ? Can a Flex component be adapted for use in Flash ? In that what I received is a .swc, I'm assuming it has to have been written in ActionScript.

Any help would be hugely appreciated. Many thanks.
bmh is offline   Reply With Quote
Old 08-27-2008, 02:09 PM   #2
Canazza
Hungry
 
Canazza's Avatar
 
Join Date: Sep 2007
Location: Glasgow
Posts: 595
Default

Flex, for one, is Actionscript 3.
A flex component CAN be adapted for use in Flash CS3 but only with Actionscript 3. You can try on the AS3 forums for some help, but I'm afraid i'm lost on how to do it. (I know it has been done, as some smart guy converted the Google maps API from Flex to CS3)
__________________
Canazza is offline   Reply With Quote
Old 08-27-2008, 03:42 PM   #3
bmh
Senior Member
 
bmh's Avatar
 
Join Date: Feb 2005
Location: Peterborough, NH USA
Posts: 117
Default

Many thanks, David. If I get this sorted out, I'll post it. -bruce
bmh is offline   Reply With Quote
Old 08-27-2008, 04:04 PM   #4
wvxvw
Holosuit User
 
wvxvw's Avatar
 
Join Date: Oct 2006
Location: Tel Aviv
Posts: 4,301
Send a message via ICQ to wvxvw
Default

Flex components do not necessarily extend DisplayObject (which is a must for Flash components). To get your Flex component into Flash you'll need to recompile it with Flex compiler adding some dummy DisplayObject relative (eg. Sprite / MovieClip) class that imports the rest of the classes. But the more simple way would be to ask for another Flash-compatible SWC =)
__________________
The .NET open source editor for Flash and web developers
*This would be my contribution to the project*
couchsurfing if you need it
wvxvw is offline   Reply With Quote
Old 08-27-2008, 04:11 PM   #5
fx.barrett
Paintball Freak
 
fx.barrett's Avatar
 
Join Date: Jul 2008
Location: Romania, TM
Posts: 467
Send a message via MSN to fx.barrett Send a message via Skype™ to fx.barrett
Default

Quote:
Flex, for one, is Actionscript 3.
Depends on which Flex version you are using.. Flex 1 for example isn't AS 3.0

Anyway, Flex > Flash. Flex is a dev environment with much better built components then the ones in Flash. So if you want better components and more flexibility then go for Flex. From what I know not all Flex components can be adapted correctly with Flash, mainly because Flex is quite different from Flash and it has tons of classes that do not exist in Flash. There will be situations when you can create flex components that behave well inside Flash but once stuff gets more and more complex the harder will you be able to make Flex components communicate correctly with Flash.
__________________
FLASHFORUM.RO - You must speak Romanian in order to join.
BLOG.WISEBISOFT.COM - Share and Experiment.
fx.barrett is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
one template, many looks? subquark ActionScript 1.0 (and below) 1166 10-29-2013 06:18 PM
Installing Flash Remoting Components for Flash 8 the ev Components 4 01-29-2010 01:28 PM
Flash Player dilemma with Flex 2. icombustion Flex 2, 3 & 4 5 01-23-2008 06:05 PM
Lost between Flash and Flex FrankyFish ActionScript 3.0 4 08-20-2007 09:47 PM
scrollBar on Flash Exchange cdeg Components 5 05-03-2004 07:13 PM


All times are GMT. The time now is 11:52 AM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.