Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 01-08-2009, 08:14 PM   #1
pixelmech
Registered User
 
Join Date: Jan 2009
Posts: 23
Default [AS3] How to programatically add tree to stage?

I'm trying to programatically add the YDN Tree to the stage via my document class. I'm clearly doing something wrong but I be stumped. This is what I am trying:

Code:
package {
	import flash.display.MovieClip;
        import com.yahoo.astra.fl.controls.List;
	import com.yahoo.astra.fl.controls.treeClasses.*;
	import com.yahoo.astra.fl.controls.Tree;
	
	public class Main extends MovieClip {
		
		public function Main() {
			
			var myTree = new Tree();
			this.addChild(myTree);
			
		}
		
	}
}
I'm getting the errors

1017: The definition of base class List was not found.

and a bunch more like

1020: Method marked override must override another method.

I assume this is because List isn't found - and it doesn't appear to be in the Astra package I downloaded - looking in the controls directory, it isn't there. Is this something I can import via flash instead?
pixelmech is offline   Reply With Quote
Old 01-08-2009, 08:34 PM   #2
CyanBlue
Super Moderator
 
CyanBlue's Avatar
 
Join Date: Jan 2002
Location: Centreville, VA
Posts: 26,666
Default

Howdy and Welcome...

Why are you importing the List class??? I don't think that class even exists... Comment out that line and see if you are getting it further...

Here is the YDN page for the Astra Tree component...
http://developer.yahoo.com/flash/astra-flash/tree/

Oh, I moved this thread to the Components forum... Please find the most appropriate forum and post your question...
__________________
CyanBlue / Jason Je / Macromedia Certified Flash Developer & Designer
http://CyanBlue.FlashVacuum.com
http://www.FlashVacuum.com
http://tutorials.FlashVacuum.com

Do NOT PM, Email or Call me... Your question belongs right in this forum...
CyanBlue is offline   Reply With Quote
Old 01-08-2009, 08:37 PM   #3
pixelmech
Registered User
 
Join Date: Jan 2009
Posts: 23
Default

Hello, and thanks - didn't see the component forum

I was only trying to import the List class, because without it I get:

1017: The definition of base class List was not found.

And this error is actually pointing to line 37 in the Tree class, not in my Main document class... so I assumed it needed to be imported, but I agree - there doesn't seem to be one. Thus my confusion...

(Also I am aware of the YDN page, I've been using the examples in the last couple days playing around with their stuff.)

Last edited by pixelmech; 01-08-2009 at 08:39 PM.
pixelmech is offline   Reply With Quote
Old 01-08-2009, 08:43 PM   #4
CyanBlue
Super Moderator
 
CyanBlue's Avatar
 
Join Date: Jan 2002
Location: Centreville, VA
Posts: 26,666
Default

Well... Let me ask you this way... Do you have the List.as file existing in the com/yahoo/astra/fl/controls directory???
__________________
CyanBlue / Jason Je / Macromedia Certified Flash Developer & Designer
http://CyanBlue.FlashVacuum.com
http://www.FlashVacuum.com
http://tutorials.FlashVacuum.com

Do NOT PM, Email or Call me... Your question belongs right in this forum...
CyanBlue is offline   Reply With Quote
Old 01-08-2009, 08:54 PM   #5
pixelmech
Registered User
 
Join Date: Jan 2009
Posts: 23
Default

Nope - so I realize it's going to bust anyway... I'm just confused on why Tree is referencing it, or wondering if I am doing something else wrong, or dowloaded the wrong package? (I downloaded the lastest one)
pixelmech 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 Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
use data provider of existing tree to populate new tree? Paulskii Components 0 09-18-2008 07:01 PM
[AS3] Multiple Button components on stage pulse00 Components 3 09-06-2008 09:31 AM
[AS3] Using ASTRA tree component Narendrakumar Components 0 08-20-2008 09:42 AM
dynamically resizing the stage for a .flv player? ykol20 ActionScript 2.0 2 01-03-2005 02:38 PM
Stage Language in Strings Panel flashch ActionScript 2.0 0 08-23-2004 11:35 AM


All times are GMT. The time now is 10:29 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.