Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




Action Trigger On Text Input



Hi.I need to trigger an action when text is written in an inputTextField. When i written a name in the input text field i want a button to appear so i can go to the next frame and the name to be recorded in a variable for future writing it in a database.Thanks.



Adobe > ActionScript 1 and 2
Posted on: 10/09/2007 07:33:01 AM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

How To Make An Input Text Field Trigger An Action When User Clicks On It To Write?
aHello everyone!

I'm trying to achieve something that I'm sure it's not that complicated, but unfortunately I have not clue how to do it.

I have created some text fields. And what I want to do, it's that when the user clicks onthem, in order to start writing, I want a specific movieclip to dissapear.

This could be achievable if I knew how to make the textfield behave like a button; but I don't know what code I need for this, as onPress it's not working at all.

Any help would be appreciated.

Cheers!

Trigger Input Text From KeyDown
Hi all,

I have a little problem with my flash form. My form has 3 input fields whice are "country code", "country name" and "calling rate" and a button "save". The "country code" field is a single letter that refer to its appropriate country. Ex: U --> United States.

What I really want to do is when user enter the country code, flash will detect the input ,send it to my PHP script, get the record from MySQL, load back to flash, fill the country name and calling rate dynamically. Then, user can edit the calling rate and hit the button to save the new rate. My problem until now is I couldn't find a way to trap the keyDown event from my country code input field. Please Help...

TQ

Validating Text In Input Field W/o Trigger
Hello,

I am working on an interactive online application training module using Flash 5.

I have a task which I need to simulate using ActionScript:

1. User types a specific name, e.g. "martin" (lower or upper case) into an input text field (which sits on a screen grab of a window). The name has a fixed length.

2. The name is validated automatically.

NOTE: The user is not required to click a button, e.g. "Submit" for the name to be validated, i.e. there is no trigger!

3. If the name was correctly typed, the play-head is advanced to a new frame (with a new screen grab). Else the user needs to try again.

Could someone please help me out with the ActionScript. Your help will be greatly appreciated.

Enter Key As A Trigger In An Input Text Field
Is it possible to create an input text field field and during keyboard entry, if the user purposefully or accidentally presses the ENTER key, some kind of action could occur, such as advancing to the next frame or whatever?

I would like to avoid using a button, unless it is technically not possible. This is what I have right now:


ActionScript Code:
if (Key.isDown(Key.ENTER)) {
               trace("The enter key has been pressed");
               }


Unfortunately, this does not quite provide me with the result I am looking for. The problem with this is, I have my focus set on the input text field, but the actionscript only reacts outside of the text input box.

Thanks

[F8] Text Input Action
Hi, I was wondering if anyone knows of a way, when an input text field is selected to hide an mc (either via _alpha or _visible). Or am I just wasting my time?

Thanks,

Robb

[F8] Changing The Text In A Input Text Box Using Action Script
Is there a way to change what text is displayed in a input text box using action script.

Input Text Action Script
I've got 2 Input Text fields and a Button on my frame

Input Text 1 is called "username"
Input Text 2 is called "password"

I'm trying to write a script for when the button is pressed it checks if username = "Fred" and password = "Smith". If it is it plays a sound if not it plays another sound.

Thanks

John

Can Anyone Help? Want Input Text To Control Goto Action
I am going to provide an input field which I want to control where the playhead goes.

The input field will ask for a specific date in a specific format. i.e...dd/mm

and when the user enters 05/23 (or May 23rd) and presses a button,

I want the playhead to gotoAndPlay("05/23");

Can anyone help me please? i know it has something to do with setting and getting properties, but I can't figure it out.

Thanks !!!

-Travie_B

Font Changes And Action Script With Input Text
Does anyone know how to use Action Script to change the font or bold or italicise or whatever (preferably of the text that hasn't been inputted yet, but either way works) of text in an input text field?

So in other words, make it so that the user can type things in, then click a button so that the text becomes bold and then another to make it italicised?

Text Input Field Flash 8 Action Script 2.o
Whenever I pass values from an input text field the value is of type string. I need to get number from the input fields, this is just not working.

Action Script Typed In Input Text Field, Performed By A MC
Hi all,

How can i have it so when someone types actions inside an input text field, the actions actually work on a movieclip in the movie?

Ex:
If someone types "_x+=_xmouse*.1" in the input text field named "input_actions" then a MC with an instance name "MC" will perform those Actions.

Is this possible? Maybe #include could be used, but that looks for external files. I dunno?

Trigger Action Between Two Swf's
Hi,

I have this problem concerning two swf files in an interface. I have created an interface in nestes tables like this:

3 cells in 2 columns: Cell A = collumn at the left of the table, Cell B = top cell in left column, Cell C = bottom-cell in left column, content in php.


Cell A holds a flash-animated cartoon figure, cell B holds an swf-menu and cell C holds an existing php-include. I would like the menu in cell B to trigger the animation in the swf file in cell A.

How do I do this? I cannot make the page one big swf file, neither can I trigger the action between two swf-files, even with the use of actionscript. At least, that's what I'm told by collegues.

Any suggestions?

Action Trigger...
Last edited by Yura : 2004-05-30 at 01:02.
























how do i trigger an action eg. gotoAndStop or w.e after X amount of time if mouse coursor is not on it anymore?

peace

Hit Test To Trigger MC Action
Is there a way to make an invisible movieclip that I can move up and down with my arrow keys, and as it rolls over another movieclip trigger the onRollOver and on RollOut functions of the movieclip it collided with. i essentially want to make the invisble movie clip act as a mouse cursor.

Not sure if i'll get a reply in time as I need to figure this out today , but if anyone out there has done something similar or knows how I can accomplish this, just let me know!

Thanks in advance!

Trigger An Action After Some Seconds
Hello!

I have this action:
sound1 = new Sound();
sound1.attachSound("som1");

onEnterFrame = function () {;
if(cabeca_mc._currentframe == 2)
sound1.start();
}

How could I trigger this sound1.start(); just after 2 seconds?
Is it with setInterval? How could I do it?

Thanks!

Enter Key On Input Field Needs To Trigger Button Click
I have a stripped down FLA here: http://www.webmarksonline.com/temp/detectenter.fla

where if you click the button, a label saying "Button clicked" will display. This was accomplished using the following actionscript attached to the button...

on(release) {
display._visible =true;
}

Now I want to make it so that when the enter key is pressed in the edit field, the same thing happens.

On the button actionscript, I have used ...

on (keyPress "<Enter>") {
display._visible = true;
}

But does not work. Why not? Google search says that this should work. I'm on Flash 8, by the way.

How Can I Trigger An Action When A Sound Stops?
Hi everyone,

I need to trigger an action when a sound stops playing. I loop the sound once, and when its over I want this to set off other actions, such as stopping a graphic equalizer. How might I do this in Flash 5?

many thanks in advance,

Jeremy Paton

My site is at:
http://www.1-language.com - The ESL Site

Trigger Action On Object Position
can you trigger an action (load movieclip for example) when an object gets to a certain x y position on the stage?, this is a scripted movement so there can be no frame actions added.

thanks in advance.

Button Fails To Trigger The Get URL Action
hi,

i have done a horizontal menu. thoug hter other links trigger the get url action the link that has the submenu wont trigge rthe action...

can some one help me why is it so?

i have attached the file

thanks
Arie

Sub Menu Fails To Trigger The Get URL Action
hi ,

i got a horizontal menu. under projects there are sub links. which doesnt trigger the action) (i.e residential, commercial etc etc ).

thanks in advance

How To Use Cursor Position To Trigger Action
Hello All,
I’m fairly new to Flash 8 (Pro) and have used only very basic actionscript.

I have made a navigation menu bar with fly-out sub-menus and have everything working correctly. Now I want to put an animated gradient background movie clip behind the menu and set it up so that when the cursor is over/within the boundary of the gradient clip it will trigger it to gotoandplay x frame, and when the cursor leaves the area, trigger another gotoandplay event.

It seems I can’t set it up with onrollover and onrollout actionscript because of the menu that sits above it, so it seems I need some way or work around to know when the cursor enters and leaves an area or set of coordinates (or in this case is above a certain y coordinate) and trigger.

I found this site
http://www.senocular.com/flash/tutorials/buttoncapturing/
which I thought might have the answer but I’m not advanced enough to follow it.

Any advice or direction will be much appreciated.

Scott

How To Trigger An Action After A FLV Has Finished Playing
I have a FLV file that I am pulling into my SWF and I want to go to the next scene in the SWF once the video clip is finished playing... Because it's externally loaded I haven't been able to figure out how to do this. I tried just importing the FLV to the stage and putting it in the timeline, but that makes the SWF huge and the video playback is much slower for some reason.

Does anyone know how to do this?

Drag Object To Trigger An Action
http://www.bigredrooster.com/flash/ball.swf

I would like to drag the small ball on the left into the square at the bottom. When this happens, the small ball should snap back to it's original position and the larger ball should play (when it plays it changes colors). Ideally, the larger ball wouldn't be visible until the ball is placed in the square. Then it would play, within the boundries of the square.

This would look like the ball was dropped into the square, and a movie (ball movie) played in the square.

If anyone can point me to a tutorial/tutorials or has any advice, I would appreciate it.

Thanks

How To Trigger This Action? ( Simple Newbie Q Please)
Hi All, I have a very simple question and I'd be glad for any suggestion for the same.

Let us say, I have an actionscripted animation on frame one, how do I trigger it to go to another frame and perfrom the actions there after completing the action on the first frame?

To illustrate, I have uploaded a trigger.fla with basic animations on frame 1 and frame 20.

How do I make the movie play out frame 1 and when that ball reaches 200px, go to frame 20 and play that action?

My purpose in this is to understand how to trigger the next event after the completion of the previous event. I appreciate help and directions towards the best way to do such. I know this is probably a very silly question for you all, but a big step for me.

Grateful and Thank You for the help.

soul

How To Use Cursor Position To Trigger Action?
Hello All,

I’m fairly new to Flash 8 (Pro) and have used only very basic actionscript.

I have made a navigation menu bar with fly-out sub-menus and have everything working correctly. Now I want to put an animated gradient background movie clip behind the menu and set it up so that when the cursor is over/within the boundary of the gradient clip it will trigger it to gotoandplay x frame, and when the cursor leaves the area, trigger another gotoandplay event.

It seems I can’t set it up with onrollover and onrollout actionscript because of the menu that sits above it, so it seems I need some way or work around to know when the cursor enters and leaves an area or set of coordinates (or in this case is above a certain y coordinate) and trigger.

I found this site
http://www.senocular.com/flash/tutorials/buttoncapturing/
which I thought might have the answer but I’m not advanced enough to follow it.

Any advice or direction will be much appreciated.
 
Scott


How Can I Trigger An Action Based On A Mouse's Position?
Seemed simple to me, but hasn't been the case, but my be simple for a script whiz:

How can I trigger an action that is dependent on a mouse's position? My scenerio involves a mouse being either IN or OUT of an odd-shaped area. I need an automatic trigger to say "hey, the mouse has left area 'X', so do action 'y'"
*also important, that it can work while the mouse is in html land, not even over the swf

(its a long story, but basically, cant use a simple rollover)

Flash help says:
The following example uses hitTest with the x_mouse and y_mouse properties to determine whether the mouse is over the target's bounding box:

if (hitTest( _root._xmouse, _root._ymouse, false));

huh? is that a typo? should it be:
(anyMovieClip.hitTest( _root._xmouse, _root._ymouse, false));

I don't understand where it refers to any MC.

Help!!?!

--------------------------------------------

If you are really wondering why I cant use a rollover, here is the long story:

I have a menu with main categories, and subcategories.

it is in a typical "Filing Tab" look and feel. So, the user rolls over a tab, to reveal subcategory buttons on the lower part of tab; in other words, bring that category's tab to the front.

So, once the mouse rolls over the main category tab, a MC moves to position where that particual tab is at the front, so now you can roll over the subcategories. if they roll out of the "Tab area", I need a way to instruct the MC to return to whatever tab it came from.

BOTTOM LINE IS, the mouse has left a particular area in the swf, and I need a way for this to be "caught", so I can assign an action.

I placed a "hidden" button on the outer boundaries, and used the MouseOver event, but if the mouse rolls to quickly off the swf into html-land, it doesn't catch the mouseover event, and trigger the return.
[Edited by cmoseman on 01-05-2002 at 08:00 PM]

Trigger Action, When Mouse Leaves Stage?
Hi,

I've made menu in flash (http://www.manuelhuertas.net/ozomate/)

which is over the iframe that displays the contents, and i wanted to know if its possible to set up an action , when the mouse leaves the "stage" of the menu movie clip, so that the menu "collapses" to its original state.

If you rollover a subject,a sub menu displays under, but if you rollover to the next main subject the one before collapses that works well, just that as I say i will like to collapse them as well when the mouse leaves the stage.

Because now if you open a subject, and you rollover the mouse under the page, the submenu, keeps displaying, which becomes anoying.

thanks for your help, if you have a clue about it!

[CS3] Action Script 2.0 Help With Conditional Sound Trigger
hi,
Can anyone tell me the reason this plays a sound (when x =1).

PHP Code:



if (_root.x=1) {
_root.firstSound.start();
}





but this doesn't?

PHP Code:



if (_root.x==1) {
_root.firstSound.start();
} else if(_root.x==0) {
    _root.firstSound.stop();
    }

Trigger Action On COMPLETION Of Stage Resize?
So here's what I'm trying to do: When the user clicks on the corner of the browser and resizes the stage, I dont want the Resize actions to occur until the user RELEASES the mouse or until the resize is complete. So, as long as they're dragging the mouse around and resizing nothing would happen, but then as soon as the mouse as released it kicks in.

I tried:
this.stage.addEventListener( Event.RESIZE, stageResizer,false,0,true);
this.stage.addEventListener(MouseEvent.MOUSE_DOWN, stageMouseDownhandler);
this.stage.addEventListener(MouseEvent.MOUSE_UP, stageMouseUphandler);

But this didnt work because when you MOUSE_DOWN on the Browser rather than the Stage, it isnt detected by the stage. And I going to have use Javascript or something?

tia,

-z

Howto Trigger Specific Action If Anything Else BUT This Btn Is Clicked?
I am not even sure how to search for a solution to this, so I'll ask here. I keep coming across this issue, where I wish I knew how to cancel, or start, one action if anything/any button BUT the last selected button/mc has been clicked. Make sense? Help. Please. Anybody.

Picture Gallery To Trigger Action In Non-flash Window
Hi people .
I am looking to make a picture gallery for a website . I want the thumbnails to be flash buttons , each who triggers a bigger picture to display on a different part of the page. The question is how do I code this since the big picture is not a part of the flash file ( only the buttons are ...)

thanks
S.

A Button Action To Trigger A Command When A Frame Is Reached
I have a button that I want to launch a pop up window but I want it to play the timeline up to a certain frame before launching the window. I cannot put the action directly on the timeline as another button needs to play through that same timeline.

Something like: On release play the timeline then stop at that labeled frame and launch the pop up window.

What's the best way to do this from a button action?

Thanks!

Calculating Input Text Field To Dynamic Field (easy Action Script)
hi. i'm trying to learn action script and i need help with this bit. i'm trying to use action script to calculate my brothers ages based on my own.

using flash MX. i have an input field called "my_age" and two dynamic fields called "eli_age" and "jacob_age". eli is 4 years younger and jacob is 6 years younger. i want to be able to enter my age in the "my_age" input field and then click a button that will calculate their respective ages.

here's the fla if i haven't been clear.

thanks for any/all help,
josh

Do An Action If "input Text" Is Not Empty
is there any way i can set the _alpha = 0 if someone is typing in the input text field.

Like:

if (input text field is not empty) {
myImage._alpha = 0;
}

Something like that?

INPUT TEXT - How To Restrict Number Of Lines Of Text A User Can Input Into Textbox
In a flash form I've created I have a input textbox. I don't want the user to be able to input more than 7 lines of text. Is this possible to do? I know that I can set a value for 'max char', but this is not useful for me -- it's essential that the user cannot input more than 7 lines of text.

How can I limit the number of lines a user can input into a textbox?


Thanks!
Glenn

Help With Email Form - Input Text Boxes Not Allowing Input
i placed an email form into a movie clip in this site...and the input text boxes are no longer allowing me to type into them.

the email form (which i got from flashkit), as it's own file, works fine, so i know it's possible...but for some reason when i take the movie clip from one file and drag it into the one i'm working on...it loses that input text funcionality. All the actionscript is the same...everything is identical...i don't get it.

i even tried to place it on top of a movie clip within the main content clip thinking maybe because it was an mc within an mc within an mc that had something to do with it...but not the case.

any help you can provide is appreciated.
(attached file was saved as MX..orig is in MX 2004 Pro)

thanks.

oh, also....how would i load movie clips to different layers?...if i understand some things i've read here, that will help me speed up the site overall...as it is VERY slow in browser. but...maybe i'm wrong.

[CS3] Trigger Text Animation Using Cue Points
Hi all,

This has probably been covered in the forums already... If it has I can't find it.

I have streaming audio (FLVPlayback) with embedded cue points - 5 to be exact. One at the beginning, one at the end and 3 scattered throughout the duration of the audio. I want text to appear when it corresponds with a certain cue point.

For instance: When cuepoint2 is triggered, I want Text2 to move into view on the stage.

Is there an easy way to accomplish this? Specific code would help a lot!

Thanks!

Dynamic Text Used To Trigger A Movie?
Hello...

Im wondering how to take specific words in a dynamic text box and use them to trigger a movie inside of flash. It seems like it would be simple but i cant figure out how to turn just a few words inside of one bigger text box into ... well.. almost buttons...

What i would like to happen is... one box has a list of dates or words... these are almost like hyperlinks i guess... when they are clicked... it triggers a movie though, instead of a URL.

does anybody understand what im trying to do? and if so... can somebody explain how to do it?

thanx

Remove Input Text On Input Text Box Select?
Right now I've got an input text box with an instance name of EMail and Var of EMail. Then in my AS I've got:

code: var EMail:String = "Enter Your Email Address";

which puts "Enter Your Email Address" in the text box when it displays. What I'd like to do is when a user clicks inside the box to enter their email address is for that string to disappear.

Input Text To Show Up In Input Text Box In Later Frame
Hi, I am making a game where the player enters his or her name into and input text box at the beginning and then prints out a certificate at the end with his or her name on it. This is the actionscript I am using, however, this only allows me to have the box where the player enters his or her name to be on the same frame as where the text appears.

input_txt.onKillFocus = function () {
user_name = input_txt.text;
input_txt2.text = user_name;
}
_global.style.setStyle("fontSize",30);

I was wondering if there was anyway to modify this script to make it so that the name appears in the input_txt2 box in a later frame.

Thanks,

Lindsay

What Are The Best Ways To Capture Input From An Input Text Field?
Hi,
I don't know ASP, CGI, PHP etc. I do, however, have a flash form with two input text fields named “E-mail” and “Name”, and a submit button.

How can I set this up so a user can input the info in these two fields and click the submit button to some how send me the data - Via Email? txt on the server? Anything...

Also, if this is not possible, what is the simplest way to learn PHP or whatever is most appropriate to get these goals accomplished.

Thanks,
Stephen

Rollover Movieclip Trigger Dynamic Text
i am trying to load dynamic text on a movie clip rollover. my instance name in this case is DynTextBox. this code works for a button but not when i apply it to a movieclip. any suggestions?

on(rollOver) {
this.DynTextBox.text="text goes here";
}

any ideas?

Trigger A Flash Function From .html Text Box
I am loading text in from an external .xml sheet and am formating that text as .html. I am wondering if it is possible to somehow create links within that .html text to trigger a function within my flash app. ?????

How Can I Trigger A Function From Hyprelink Text Within Flash?
hi.

i am dynamically generating text inside an HTML text box, and i'd like the assign certain parts of the text hyperlinks that will trigger certain functions that i declare inside flash.   any thoughts?

thanks in advance!

Flash Text Links That Trigger ActionScript
I am trying to create a list of links in a dynamic text box. But I don't want the links to go to a url. I want to have them use Actionscript to jump to a certain marker in the timeline. Is there a way to do this? Any help greatly appreciated.

- Luke

No User Input After Sometime, Do The Action
Hey everybody,

I am sure someone already posted this question before, but I searched and did not find it...very simple:

I have an animation that is suppose to happened after the user clicks the button - but I want a script that does the action after sometime, if the user did not click it - can anybody help me??

Many, many thanks!!


Fernanda

Wat Is The Action Script For Keyboard Input?
i have created 12 piano keyboard keys on my screen.. i want my users to have keyboard input using the computer keyboard
eg: the letter 'a' for the piano key "a"

when the user press "a" on the computer keyboard, the sound of that key should also apprear..
wats the action script?
pls help..

Wat Is The Action Script For Keyboard Input?
i have created 12 piano keyboard keys on my screen.. i want my users to have keyboard input using the computer keyboard
eg: the letter 'a' for the piano key "a"

when the user press "a" on the computer keyboard, the sound of that key should also apprear..
wats the action script?
pls help..

Trigger An Action Outside Movie From Within Movie
I have an HTML page that has a large image map (JPG) with multiple 'divOfArea' coordinates (hotspots) on it. The hotspots have animated GIFs assigned to them.

I would like to insert a Flash movie in my HTML page and use it to control the actions of my image map. In other words, have a GIF image appear on the image map (outside the movie) when the user clicks on a button inside the movie. Can this be done?

Copyright © 2005-08 www.BigResource.com, All rights reserved