Tell Targets - Do they smell?

I am in a similar situation to csbryce - I too have five buttons that I am trying to link to separate tell targets, which are also scrolling text boxes. I notice csbryce has got no replies - is this because the question is just too darned easy and we are missing something really obvious - or because tell targets smell?

I have done the scrolling text box fine, (who needs MX?). I have created separate symbol movie clips with the boxes in and named them as per Kirupa’s tutorial. My problem is that I cannot seem to then drag them onto the stage from the library. Even if I did, I have a huge stage - where do I drag them? to different frames I assume?

Were I able to do this, would I simply link each button to the keyframe that they referred to. So that would be gotoandplay 300, 301, 302, etc?

At the moment I’m getting ‘target not found’.

Also, if I am flitting from frame to frame, how can I keep audio playing? At the moment it’s played with a simple gotoandplay command at frame x - presumably if the buttons are activating separate frames to get the text boxes changing, the music will die - Don Maclane would not be pleased.

Not so bothered about the audio - but if any of you flash gurus wouldn’t mind putting a clothes peg on your nose and helping us get these text boxes responding properly, it would be much appreciated.

Have you made you that all your instances that are placed on the stage have an instance name? Probably an obvious statement to make, but that could be why the code isn’t finding them.

Yes- they have instance names.

I can’t find a multi-button tell target tutorial either which is bizarre because I’m guessing this is common ground.

Kit, any chance I could mail you the fla for you to have a look - this is driving me nuts :crazy:

This is so - depressing. I’ve been trying to link this little lot up all day now and I’m not getting anywhere. Maybe I’m being a little ambitious for a first tell target effort, but I don’t see why this shouldn’t work perfectly well.

Don’t you hate it when you try and try to do something in Flash and the pieces just won’t seem to come together.

Hoorah - it’s sorted. The problem was, though I’d named the instances I intended to include, they weren’t actually on the timeline. The only instance that was there - wasn’t named. The text boxes different parts were confusing me.

The script if anyone is remotely interested is:

on (release) {
tellTarget (“textbox”) {
Text = “<P ALIGN=“LEFT”><FONT FACE=“Arial” SIZE=“10” COLOR=“999999”>text</FONT></P>”;
tellTarget (“textbox”) {
if (scrolling == “up”) {
if (scrolling == “down”) {


are you using Flash 5.0?

It is in the Flash 5 section david=)

Yes… but we don’t have a Flash 4.0 section.

I would say that the code is outdated because tellTargets no longer look like that. With the addition of dot syntax coding in Flash 5.0 everything would be much more compact. There would be less scripting involved.

Sorry didn’t reply sooner to this. Guess the time difference is a bit of a pain as well. :slight_smile:

Looks like you got it sorted OK, but if you’d like me to take a quick look at it then mail it to [email protected].

Although I’ve just realised that I’m only here until about 5.30 (British time) today, then I’m off in Portugal for a week…

Well - sort of sorted, just ironing out a few niggles now.

David, hello mate, yes it’s flash five - what do you think the code should look like instead? I’d be interested to know.

Have a sneaking suspicion that tell targets may sort out the music problem as well. Invisible object on the stage with the music looping in it sound right?

dot syntax is similar to the tell target… but you’re not using so much code, and the slashes have been replaced by periods. Your code would look something like this

on (release) {
textbox.Text = “text”;
if (textbox.scrolling == “up”) {
if (textbox.scrolling == “down”) {

Though what effect that will have, I’m unsure of. Usually there are small nuances to switching over to OOP Dot syntax.

The basic deal is this. With Flash 5.0 you can now call out directly to any movie clip object (arrays; xmlnodes; string variables, also) and tell it to do something, or read a property of it.

so if you have an movie clip with an instance name of “textbox”, all of these commands have the following effects.

i=textbox.length(); //if this is a string var, it will set i to equal the number of characters in the string.

textbox.gotoAndPlay(2); //if this is a movie clip it will send the play head to frame 2 and start it playing.

textbox.scatterText.begin(); //calls a user defined function called “begin()” which is located inside an object called “scatterText” which is located inside the “textbox” object.

textbox.myVariable=“It was the best of times it was the worst of times.”; // sets a variable called “myVariable” in textbox object, equal to the value of the string.

Anything you could do with slash syntax tellTarget you can do with dot syntax more easily.

In slash syntax if you wanted to go backwards up the tree of objects you’d have to use …/ or something like that. In dot syntax the parent object of the object can be refered to with the word _parent in the dot structure. The main timeline that contains all others can be called to by _root, and any level can be called to by _level#.


Text box action script now adjusted.

Thank you guys - David, Kirupa and Kit especially for your kind words and vital help in getting the site finished. The beta is now up, scrolling text box action script now a la David. It all seems to work fine - just some content to go and maybe up the frame rate - depends how it loads.

The only thing re text boxes that I’d like to change is have the text box move (as well as fade) in under a mask, which it doesn’t seem to want to do… but that’s another thread.

lol… yeah it might be.

I did forget to say one thing that I really wanted to.

tellTargets DO smell…badly. :slight_smile: