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








Clicking A Textfield: Why Do I Have To Hit The Letters?


Hi!

I feel silly with this... problem. I made a button out of a textfield. I can click it.

But why do I have to hit the text itself to trigger the button and not any area of the textfield? I mean, if I hit the empty space of the letter "o" for example, the button does not detect the event.

How silly is that!?

Thanks for your help with this.




ActionScript.org Forums > ActionScript Forums Group > ActionScript 2.0
Posted on: 02-24-2007, 06:02 PM


View Complete Forum Thread with Replies

Sponsored Links:

Textfield In ScrollPane > Textfield Only Accessible With Clicking Twice
hi!

i have a scrollPane on the stage which contains an editable textfield.
unfortunately i can only access the textfield in the pane when i click on it twice. it seems that the first click goes for the activation of the pane and then comes the textfield.

does anybody have an idea how to solve that problem?


// Text Field
var myTextField:TextField = new TextField();
myTextField.text = "Please insert text";
myTextField.selectable = true;
myTextField.type = TextFieldType.INPUT ;

// ScrollPane
var myScrollPane:ScrollPane = new ScrollPane();
myScrollPane.source = myTextField;
addChild(myScrollPane);

View Replies !    View Related
Get Length Of Letters In Textfield
Hey all,
I've got a movie with a horizontal line graphic to the right of a dynamic textfield for a page title(it's pulling the text from a PHP variable).I would like the line to always follow just behind the last letter of whatever text is passed. Is there a piece of actionscript that gets the "length", or perhaps "width", of letters in a textfield so I can dynamically change the x position of the graphic?

oskom

View Replies !    View Related
Random Letters On Textfield
I have several textfields, and on each one I´d like to have a random letter to appear. No ciclying, just to appear.

I´d tought about putting a letter on each frame of a movie clip and making the frame random, but maybe the letters beeing danamic could make the swf lighter.


is it possible?

View Replies !    View Related
Colouring Individual Letters In TextField
Hi,

I was wondering if somebody could offer some assistance as to how one would colour individual letters in a textField.

I have noticed in CS3 that you can only do this in static textFields, but you can not create these via actionscript which is what i would optimally like because i will be using a fair few of these types of objects.

Is the only possibility to make the amount I need in the FLA file and get a handle to them from the as file or is there a textClass i have missed?

Help is much appreciated!

-Mats

View Replies !    View Related
Addressing Individual Letters In Dynamic Textfield
Hi there,
i couldn't find anything about it, so is there a way to address individual letters in a dynamic textfield? I'd like to do some text tweenings but could not find a poper way of instanciating single letters. Of course it is possible to create a new textfield for text-values stored in an array, but this seem to be quite inefficient to me.

View Replies !    View Related
Check Whether Characters In Input Textfield Are Numbers Or Letters?
I just can't get this right.
I have two textfields:inputTxt (INPUT)
statusTxt (DYNAMIC)
I have a button, which when pressed should check whether the characters entered into the input field are numbers or letters.
I have tried:

Code:
private function onMouseUp(evt:MouseEvent):void {
if (isNaN(inputTxt.text)) {
statusTxt.text = 'You have not entered a number';
}else {
statusTxt.text = 'You have entered a number';
}
}
I realise now that isNAN() only checks a variable value rather than a string value.
How does one do this?

View Replies !    View Related
Check Whether Characters In Input Textfield Are Numbers Or Letters?
I just can't get this right.
I have two textfields:

1. inputTxt (INPUT)
2. statusTxt (DYNAMIC)

I have a button, which when pressed should check whether the characters entered into the input field are numbers or letters.
I have tried:

private function onMouseUp(evt:MouseEvent):void {
if (isNaN(inputTxt.text)) {
statusTxt.text = 'You have not entered a number';
}else {
statusTxt.text = 'You have entered a number';
}
}

I realise now that isNAN() only checks a variable value rather than a string value.
How does one do this?

View Replies !    View Related
INPUT Textfield Does Not Show Non-English Letters With Transparent Mode
INPUT textfield does not show non-English letters when i type, if transparent mode turn on

this is bug of Flash Player 9?
will this bug had be fixed?





























Edited: 02/18/2008 at 07:56:22 AM by Stepik_true

View Replies !    View Related
Execute Function Clicking In Textfield
I want to execute a function as soon as user clicks in a textfield. there are probly a few ways to do this . . . . me no know!

View Replies !    View Related
Clicking On A Sprite With A Textfield Child
Hello kirupers!!!

I've been out of as3 for a few weeks but when I start coding again, I start coming back again to the forum

I have a movieclip in the library (menu_button) which only consists of a textfield. This is an item of a dynamic menu I build by adding new instances of the menu_button class.

It seems that when I click in the movieclip, it's the textfield that fires the mouse event, instead of the movieclip which contains the textfield.

Whe I do trace(event.target.type) I get "dynamic" (for dynamic textfield I supose...)

Another problem I have is that when I do menu_button.buttonMode= true I don't get that gloved hand we all love...

this should be simple... Am I missing something important?

TIA!

Pier

View Replies !    View Related
Removing Dynamicaly Created TextField Clicking On It Itself
please!
does anybody now how to remove dynamicaly created TextField or MovieClip by clicking on it itself?
Thanks.

View Replies !    View Related
Convert The Letters To Lowercase ONLY If They Are Actually Letters, Not Numbers?
I have a glitch with this line of code:

one_array.toLowerCase();

in a dynamic input textbox. If the string includes a "!" it becomes a "1" .

Is there a way to only convert the letters to lowercase if they are actually letters - not numbers or punctuation? Do I have to write a line of code for each character, or is there an easier way to do it?

View Replies !    View Related
Clicking Lingage Inside Library. I Think Im Braking A Clicking Record ..
I´m going crazy I have to export 773 files inside my library. All files are small sound clips. So I have to right click 773 times and choose export for actionscript. However the filenames are just as I want the identifier to be so if there would only be a command like

"Export selected items for actionscript using the current filename "

it would save my day.

If anyone know how to do this in a quicker way please let me know.

Thanks

View Replies !    View Related
[mx + Flash8] Different Mouse Events For Clicking Or Clicking And Dragging
Hi there,

there's something that nearly makes my head explode ...i'm in desperate need for your help

what i want to achieve is an online magazine where you can:
- flip the pages by clicken on the corners
- click on the pages to zoom in
- if zoomed in, click to drag the page around
- click again on the page to zoom out.

like in this example: http://www1.visions-weekly.de/epaper/epaper.html

what i have so far is:

as i'd never ever be able to program the pageflip thingy myself,
i bought a pageflip component from the lovely guys at flashloaded.com, so the magazine itself is set up, all the pages are in and i can flip them by clicking on the corners ...sweeet

now comes the tricky part (at least for me)

i put an invisible button on top of the book. i started with the zoom function and used the onClipEvent(mouseDown) and (mouseUp) functions. if clicked for the first time i scale (xscale, yscale) the book to 120%. on the next click i zoom back to 100%. That worked out of the box

Now i wanted to integrate the dragging. the book shall be dragged only when the mouse button is pressed ...but i didn't find a function for that. What i can achieve is either drag it after it got clicked or drag it always when clicked.

for example i tried this code:

i defined 3 variables in the main timeline:

firstclick (to monitor if it is the first click or not)
clicker (to monitor if the button is clicked right now)
dragger (to monitor if the book gets dragged)



Code:

onClipEvent(mouseDown){
if(_root.firstclick=="0"){
_root.firstclick="1";
}
else{
_root.clicker="1";
}
}
onClipEvent(mouseMove){
if(_root.clicker=="1"){
_root.dragger="1";
_root.mybook.startDrag();
};
}
onClipEvent(mouseUp){
if(_root.firstclick=="1"){
_root.mybook._xscale=120;
_root.mybook._yscale=120;
_root.firstclick="2";
}
else if(_root.dragger=="0"){
_root.clicker="0";
_root.firstclick="0";
_root.mybook._xscale=100;
_root.mybook._yscale=100;
_root.mybook._x=10;
_root.mybook._y=10;
}
else if(_root.dragger=="1"){
_root.dragger="0";
_root.clicker="0";
_root.mybook.stopDrag();
}

}
the zooming works but not the dragging (i presume because the dragging would start after the click not while the button is pressed.

i tried to work with listeners (for the first time) but to no avail, because if i listen for clicks or drags that interfered with the pageflip function where you click and drag the pages as well.

can some one ...pretty pretty please ... show me a better way to achieve this?

yours
Stefan

View Replies !    View Related
Replacing Letters With Other Letters
I am trying to make a simple encryption tool and i was wondering how i could use code to replace text, with somewthing totally different!

View Replies !    View Related
Transforming Letters To Letters..? Is It Possible?
do you guys know if its possible to transform letters into a different letter because i'm sorta stuck thx for your help

View Replies !    View Related
Loading Text & JPG Nito TextField Makes Textfield White
Hi guys !

Does anyone know, why a textfield may become white when loading text + JPGs into it? Sometimes it happens to me, sometimes not. I haven't figured out why.

If you have any clues... I'd be really thankful

The AS I'm using:

_target.container.t.html = true
_target.container.t.condenseWhite = true
_target.container.t.autoSize = "left";
_target.container.t.htmlText = _data.texto

The String ( &HTML ):

"Text lorem ipsum bla bla ..... <img style='WIDTH: 154px; HEIGHT: 59px' height='298' width='856' alt='' src='http://www.spacilong.com/arq/img/AlcatelLucent_Hor_2col_sm.jpg' />

View Replies !    View Related
I Need To Know How Much Letters
help!!!
I need to know how much letters are into a specific line of a dynamic text string...for exampe:
FirstString = .....lenght;
SecondString= .....lenght;
etc....

View Replies !    View Related
Letters And ASP
I have a strange problem.
I'm working on this website where we combinate Flash and ASP.
Everything is working fine, except that we can't use the special letter for the norwegian language.
On the other way we can "hardcode" it in flash and it's working there. We can set a variabel with these letters, and it's working. But we get problems when we read from the ASP script.

Here is some of the code.
function getnewsText()
{
var n = new LoadVars();
n.newsheading = nyhetvalg;
var m = new LoadVars();
m.onLoad = getResponse;
n.sendAndLoad("news/maintext.asp", m, POST);
}

Anyone who have had that problem?
I'm pretty confused and I'm not shure that the problem is in the Flash file or the asp script file.
It's seems that is working both places but not together.

I hope somebody can help me.

Remi

View Replies !    View Related
'dot Letters' Ö Å Ä MX
Hi
Odd question for those who write in english but when i import text from a .txt file
onClipEvent (load) {
this.loadVariables("pajala.txt");
the 'dot letters' ä ä ö shows as boxes http://ullvitorget.koping.se/~JTR/test/pajala.swf
When i write text in actionscript there is no problem? Why?
// Roland

View Replies !    View Related
Using Letters
I need the code to make it so when I press "w" something happens.

View Replies !    View Related
Textfield Woes, How To Anti-Alias A Dynamic Textfield?
this is driving me nuts, even if i have it marked so that my dynamic textfield is anti aliased, it still looks as if its text is aliased. And if i simply make that textfield Static, the text all of a sudden looks amazingly crisp and anti aliased.

How can i fix this?! I am attempting to load xml data into my text fields but its wasted if the text looks like crap..

So can anyone enlighten me on how to do this? i tried searching Flashs help, all i came out with was "Textfield._quality" but i do not understand what the description means exactly.. And i tried coding my textfield to _quality = "BEST";, with no avail.

Please help, i'v seen other websites with what i am sure is dynamically loaded fields, and smooth looking text... so what gives?

Thanks!

View Replies !    View Related
[textfield] How To Check If Input Text Is More Than Textfield Height?
Hi guys, Is there a way to check if the text that has been input into the textfield is more than the height of the textfield.

I have set the scrollbar hidden and it will become unhidden once the text is greater the the textfield height.

I did try to count the input text and set the visiblity of the scrollbar against that count. Unfortunatly this is unreliable.

Anyone got a better idea?

Cheers
Paul

View Replies !    View Related
[textfield] How To Check If Input Text Is More Than Textfield Height?
Hi guys, Is there a way to check if the text that has been input into the textfield is more than the height of the textfield.

I have set the scrollbar hidden and it will become unhidden once the text is greater the the textfield height.

I did try to count the input text and set the visiblity of the scrollbar against that count. Unfortunatly this is unreliable.

Anyone got a better idea?

Cheers
Paul

View Replies !    View Related
Link In Dynamic Textfield To Jump To Section Of Same Textfield
Howdy all,

I know you've all seen this before - you are on a website and you click a link and you stay on the same page but jump down to a different section of the page. Like an FAQ page or something where all the questions are listed above but you click on one and jumps down to the answer below.

Is it possible to do this in a dynamic (scrollable) textfield with externally loaded text files in Flash? I don't have DW and I know that there are limited html tags available but if anyone knows an easy way to do this please let me know!

thanks!

View Replies !    View Related
After Killing The Focus On A Textfield, The Textfield Remains Selected. Why ?
Hi.
I have a serious problem with the deselecting text when I kill the focus on a textfield.
to see better what I am trying to say, please clcick this link: http://www.eurogaz.ro/rring/expert/

View Replies !    View Related
Link In Dynamic Textfield To Jump To Section Of Same Textfield
Howdy all,

I know you've all seen this before - you are on a website and you click a link and you stay on the same page but jump down to a different section of the page. Like an FAQ page or something where all the questions are listed above but you click on one and jumps down to the answer below.

Is it possible to do this in a dynamic (scrollable) textfield with externally loaded text files in Flash? I don't have DW and I know that there are limited html tags available but if anyone knows an easy way to do this please let me know!

thanks!

View Replies !    View Related
Submiting Letters
I want to make an internet site where my friends can get to write on a flash interface so whatever they write appears on the page, like writing open letters or something like that.. do you know what i mean?? It's kinda like this i'm doing right now, i write this thread and it gets published.... PLEASE!!!! someone :-)

View Replies !    View Related
Shaking Some Letters.....
Hi

I'm trying to have a bunch of random letters in a circle. You can grab this circle and move about the screen - which makes the letters look like there being shaken....but what i've done is very rigid....the letters follow the circle to but it hasn't got a random like feel......any help would be appreciated.

thanks

View Replies !    View Related
What Do The Letters SWF Stand For Exactly?
A simple query. I know that it is the flash file format.
Does it stand for scalable web format?
Thanks in advance Sebastian

View Replies !    View Related
Test For Cap Letters
is there any way to test if a particular substring is a capital letter? I would rather not do 26 if else statements....

thanks

View Replies !    View Related
? Spanish Letters ?
Hi, i need to use spanish letters (some of them have minor drawings above them).
Do i put them inside the "Embed Fonts" in the "text options" window and that will do?

Thanks in advance,
Maya.

View Replies !    View Related
Shuffle Letters
Hi all!

I have a variable = "REFERENCER".
I want to have each letter to shuffle around randomly at the
same time. After a certain amount of time, each letter ends with the right letter. (REFERENCER).

It should be something like this example, but only the letters should change at the same time.

http://www.flashkit.com/movies/Effec...32/index.shtml

View Replies !    View Related
Scandinavian Letters
This time I have a big problem. I am loading text dynamicaly from a *.txt file. This i ok. The problem is when I type any "scandinavian letters" like Æ Ø or Å they appear as squares in the text-field. I really want to have this letters because not everybody who is reading my page can speak English.

Is this possible? I am sure our asian friends has the same problem..?

Is there a way to work around this?

Happy flashing, Metaman

View Replies !    View Related
My .TXT Does Not Show Some Letters
ok guys here it is.
i all ready know how to load a .txt file into a dinamic textfield in flashMX. The thing is that i´m trying to load a spanish peace of text that has some á,é,í,ó,ú and the Ñ letters. When i upload the .txt file, it does not show those letters in my movie.

Thank you guys, i going nuts with this little problem.

View Replies !    View Related
Jagged Letters
How can I make my text look more smooth? Even when I have it set as Static Text it looks jagged.

View Replies !    View Related
Random Letters?
Is there away to get random letters? I know there are for numbers, but unsure of letters.

I am trying to get text to reveal itself as it does in:

http://www.thisdotcomtaken.com/v5/main_load.html

A group of numbers and letters changing at the fps speed and then magically spells out the word. Each time is random in which letter stops first, so I'm figuring that each 'letter space' of the word would have a random value of how many times to go through the loop until it equals the appropriate letter. Is that the best way?

But it still comes down to me being stuck about how to get a random letter.

any help would be much apprecaited.

ty

View Replies !    View Related
Moving With Letters
Hey there everyone... I just have one quick little question. Ok, so you know how you can move things with the arrow keys right?

if (Key.isDown(Key.LEFT)){
_root.blah._x+=1;
}

well, how in gods name would you do this for a letter? Like the "w". Thanks in advance.

View Replies !    View Related
Writing Letters
Hi,

I've seen many times the cool effect as if someone is writing a text in flash.You can see how the letters are written. Can anyone tell me how I can do that? It has to be realistic though :-)

Thanks in advance
Greetings
Camme

View Replies !    View Related
Writing Letters
Hi,

I've seen many times the cool effect as if someone is writing a text in flash.You can see how the letters are written. Can anyone tell me how I can do that? It has to be realistic though :-)

Thanks in advance
Greetings
Camme

View Replies !    View Related
Expanding Letters
I have a movie which duplicates to animate letters falling from the sky and spelling a word. However, the last bit of the animation scales the letter by 400% to make it more readable but when I do this the letters all end up overlapping each other. I could increase the _x gap between them during the duplication loop but then the animations widen out off the stage. So the question is, how do I adjust the _x value of the final resting place using the loop variable from the duplication script? Whatever I seem to do seems to do nothing!
Thanks!
Ig

View Replies !    View Related
Counting Letters
I need to know if it is possible to count letters in groups of five when a user is typing in a input box.

View Replies !    View Related
Inflating Letters
i am having great difficulty trying to get letters to appear as though they are being inflated with air. i would like inflating sounds to go with it if possible.....can any of you "swish masters" plese help me out with this one???

any help would be greatly appreciated!!!

thanks in advance
Scott

View Replies !    View Related
Strange Letters
i am from sweden.... and i want to insert text from a .txt to a dynamic textfield. in the txt it says:

hej jag är jonas bla bla bla bla

and ä is not shown (here we have strange letters).

please help... it is enoying that flash isn´t international....

thanks
/black_emperor

View Replies !    View Related
Mirrored Letters
Hey Guys!

I have some strange thing going on with my Flash Movie (I made it with Swish). When I put my file online (as intro on a site) the letters of the intro are mirrored, turned, ...

You can see it here: http://www.thescreen.be

When I play the file on my PC everything is fine.

How can I solve this?? Thx..

View Replies !    View Related
Japanese Letters
I have a client from Japan who needs some Japanese Lettering. Can anybody tell me where to find them?

Thanx
CobyCo

View Replies !    View Related
Space Between Letters
Hi all...

Anyone knows how to change the space between letters (kerning) of a dynamic text?

I've tried doing it with AS but no way. I know it can be done for static text, but for dynamic... sometimes flash is so illogical and confusing.


Regards

View Replies !    View Related
How To Get The Letters Show Up
Hi how do I get these letters to show up in my movie there parts of letters that needs to be in a word.
é,à,â,ç
These letters are part of the french language, and when I look at my movie there missing in the words, and withought them the word makes no sense, hope you guys understand what I mean

View Replies !    View Related
Hey Cool Letters How ?
hey take a look at this site, Julian Valencia
now in the showroom section i want to learn how to make does cool letter fall down in 3d any examples, tutorials or something ?? thanks

View Replies !    View Related
Fuzzy Letters
Most of the time when I use Arial anti-aliased font at 10px, it turns fuzzy when I play the movie. Anyone know what causes this, and/or how to stop it from happening, because it's getting really annoying with the site I'm working on.

View Replies !    View Related
How To Cutout Letters?
I want to cutout some text so light can shine through from the back. Create a rectangle the same color as the background, put text on it and then cutout the letters. Make a layer underneath with a motion tween of white light scrolling across.
I can do everything except get holes for the text..??
Thanks

View Replies !    View Related
Copyright © 2005-08 www.BigResource.com, All rights reserved