RSS
 

Archive for July, 2008

Fixing the Flash CS3 Flex Skin Template classpath Bug

31 Jul

I’ve been using the Flex Component and the Flex Skinning Templates for Adobe Flash CS3 for awhile now. I couldn’t figure out why Flash CS3 would throw up this error at certain times:

A definition for the base class could not be found in the classpath. Please enter the name of a class that is defined in the classpath, or enter the default base class ‘flash.display.MovieClip’.

Today I found the answer in the comments of the Flex Community Blog post about “Turning Flash CS3 assets into Flex Components“.

If you’re using the Skinning Templates by Adobe to create new skins for your project you’ll want to pay attention to this little item during your workflow.

I usually open the Flex Skinning Template in Flash CS3 via the “New” dialog box.

In the example of skinning a Flex Button Component. Once I open the Flex skinning template, I duplicate the symbol in the library because more often than not I will be creating multiple Flex Skin’s for a single Flex Button Component.

If you’ll notice below in the “Symbol Properties” dialog box the default Base class for the component is “mx.flash.UIMovieClip”

If you duplicate the symbol (see below), Flash CS3 changes the Base class to “flash.display.MovieClip”.

The thing to note here is if you publish your file and import the new skin into Flex Builder, your skin states will automatically play like an animated gif. Also, if you try to type in the “mx.flash.UIMovieClip” Base class path you will get the error message above.

The admin on the Flex Community blog today resolved this for me in his comments on this post and quoted below for clarity.

“I’m sorry, It appears I have mislead you with an error. I went through my steps from the beginning, and found that you need to set the base class as flash.display.MovieClip. Flash then automatically changes it to mx.flash.UIMovieClip after you click commands -> convert symbol to Flex component. You can see this change if you go to the linkage window for the symbol after you create a Flex component from it. I’m sorry for the frustration, I try to keep these articles as error free as possible, but this one slipped through. Try this and let me know how it works for you.

If you still have a problem, let me know before googling your eyes out further (I know how that is), and I’ll help you get it. It’s a great tool.

P.S. I have corrected this in the article.”

So if you encounter this problem when you are trying to bring in an animated Flash skin into Flex, converting the symbol to a Flex component command could help. See below.

Thanks Admin, I’m not sure who you are but you helped me a lot today.

 
 

Flex + Flash + Maya for 3D UI button controls

19 Jul

3D is a passion of mine. I’ve been doing some experimenting exporting 3D rendered stills from Maya to Flash and then finally to Flex. I like the concept of creating GUI elements that are squashy, transformed or deformed in some way. I’m hoping to create an entire interface with 3D elements. Maybe blend these elements with video for a Game like experience? We’ll See…Here’s where I am so far.

3D Rendered GUI Flex Skinned Components

Rendered 3D Flex Skins