PDA

View Full Version : 2 tricky questions


de_la_soul
07-20-2005, 07:24 AM
I have 2 tricky questions that I have struggled with for the last two days.

The first is how do I determine the class path of a 3rd party component that
I have installed?

The second is how do I get my custom classes to talk to components that have
been instantiated inside of them? The component works on the root timeline,
but once it's inside a custom object(i.e. class CustomObject extends
MovieClip {}) it behaves strangely. I can set some properties like
dataProviders and what not. But none of the methods seem to work. Like the
ComboBox for Example, it populates but it wont open. I'm sitting here with
the dicionary open, and I know I'm doin it right... but they just wont work.

I heard there was an issue where components would stop working if they were
inside of a MovieClip that had getNextHighestDepth() used on them, is this
true? Perhaps I'm having a problem with not Type casting correctly, but how
do I determine what the Type is of a 3rd party component when there is no AS
file included.

I'd appreciate any thoughts you have.

Steven de la Torre
http://www.wheniwoke.com

sleekdigital
07-21-2005, 08:05 PM
For your second question, you need to be more specific about what you are doing and provide some code to illustrate.

For your first question, that inforamtion should be readily available from whoever created the component.

xxlm
07-22-2005, 04:40 AM
for your second question you need to specify the owner, like

class myclass {

private var _lvMyLoadVars:LoadVars;
private var _sEcho:String = "I'm a private of the class myclass";

function myclass() {
_lvMyLoadVars = new LoadVars();
_lvMyLoadVars._owner = this;
// then from inside you LoadVars object, if you want to access private var of the class
_lvMyLoadVars.onLoad = function(ok:boolean):Void {
trace(_lvMyLoadVars._owner._sEcho);
}
}
}


Hope it's what you were looking for... ;)

C ya