RE: [flexcoders] Loading classes at runtime from RSLs, SWCs etc.

2007-12-13 Thread Alex Harui
Modules.  See my blog (blogs.adobe.com/aharui)

-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Lachlan Cotter
Sent: Thursday, December 13, 2007 1:29 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Loading classes at runtime from RSLs, SWCs etc.

Hi All,




I was wondering if someone can offer some advice on dynamic loading  
of classes at runtime.

What I would like to achieve is to create a library of view classes  
(effect classes to be specific) which can by dynamically loaded into  
a Flex application at run time. I don't want to re-compile the main  
application when new classes become available.

All the classes will conform to an abstract interface.

Ideally, when new classes are available, I want to compile them into  
SWC files and place them in a directory on the server so that next  
time the Flex application is run, it can detect the available classes  
and present a list that the user can choose from.

I've got the idea you can do something like this with SWC files  
published from Flash CS3.

Can someone point me toward some resources or offer some tips that  
might help me ask a better question.




Cheers,
Lach


[flexcoders] Loading classes at runtime from RSLs, SWCs etc.

2007-12-13 Thread Lachlan Cotter

Hi All,




I was wondering if someone can offer some advice on dynamic loading  
of classes at runtime.


What I would like to achieve is to create a library of view classes  
(effect classes to be specific) which can by dynamically loaded into  
a Flex application at run time. I don't want to re-compile the main  
application when new classes become available.


All the classes will conform to an abstract interface.

Ideally, when new classes are available, I want to compile them into  
SWC files and place them in a directory on the server so that next  
time the Flex application is run, it can detect the available classes  
and present a list that the user can choose from.


I've got the idea you can do something like this with SWC files  
published from Flash CS3.


Can someone point me toward some resources or offer some tips that  
might help me ask a better question.





Cheers,
Lach

smime.p7s
Description: S/MIME cryptographic signature


[flexcoders] Loading classes

2005-08-26 Thread Prasad Dhananjaya
Hi All,

I want to draw two squares inside the canves.
I define "DrawIcons"class. My class file and MXML file is in the same
directory. When I run this, it says "The class "DrawIcons()"could not 
be loaded" (line of error is "var Square1:DrawIcons = new DrawIcons(100, 200);")
Can someone please tell me what's the wrong with this code?

Thanks,
Prasad
(Absolute beginner of 
Flex & ActionScript,
Studying using of classes)

--square.mxml---
http://www.macromedia.com/2003/mxml";>









---


-DrawIcons.as--
//Class definition
class DrawIcons {
var xValue:Number;
var yValue:Number;

//Contractor
function DrawIcons(cordiX:Number,cordiY:Number){
this.Xvalue=cordiX;
this.Yvalue=cordiY;
  }
//Drawing square
function createSquare() {
var square_mc:MovieClip;
square_mc = 
MyCanves.createEmptyMovieClip("square_mc",getNextHighestDepth());
square_mc.lineStyle(1, 0x00, 100);
square_mc.beginFill(0xFF, 100);
square_mc.moveTo(0, 0);
square_mc.lineTo(50, 0);
square_mc.lineTo(50, 50);
square_mc.lineTo(0, 50);
square_mc.lineTo(0, 0);
square_mc.endFill();

square_mc._x = this.Xvalue;
square_mc._y = this.Yvalue; 
   }
}




 Yahoo! Groups Sponsor ~--> 
Fair play? Video games influencing politics. Click and talk back!
http://us.click.yahoo.com/T8sf5C/tzNLAA/TtwFAA/nhFolB/TM
~-> 

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/