Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 06-03-2004, 02:44 PM   #1
swive
Registered Loser
 
Join Date: Jun 2004
Location: MN
Posts: 29
Default Help with TextField.restrict

Flash MX

In the first frame of my movie, I have a textfield with the name 'text1'

I also have some frame actions in the first frame:

text1.restrict = "0-9";
text1 = "";

When I test this movie, I am still able to enter characters into the text field. Even if I take out the second line I can still enter characters. Why?

-K
swive is offline   Reply With Quote
Old 06-03-2004, 03:19 PM   #2
CyanBlue
Super Moderator
 
CyanBlue's Avatar
 
Join Date: Jan 2002
Location: Centreville, VA
Posts: 26,666
Default

It shouldn't be... It looks like 'text1' is the variable name of your textField... You need to make sure that you are referencing it with the textField instance name rather than the variable name when using with the 'restrict'...

Please keep one question to one thread... Thank you...
__________________
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 06-03-2004, 03:23 PM   #3
swive
Registered Loser
 
Join Date: Jun 2004
Location: MN
Posts: 29
Default

i understand.

and sorry about that.
swive is offline   Reply With Quote
Old 06-03-2004, 03:24 PM   #4
CyanBlue
Super Moderator
 
CyanBlue's Avatar
 
Join Date: Jan 2002
Location: Centreville, VA
Posts: 26,666
Default

Not a problem... Did that solve your problem???
__________________
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 06-03-2004, 03:25 PM   #5
swive
Registered Loser
 
Join Date: Jun 2004
Location: MN
Posts: 29
Default

that did it.

is there going to be a problem if my variable name and instance names are the same?
swive is offline   Reply With Quote
Old 06-03-2004, 03:26 PM   #6
CyanBlue
Super Moderator
 
CyanBlue's Avatar
 
Join Date: Jan 2002
Location: Centreville, VA
Posts: 26,666
Default

Um, nope... But I advise you NOT to use variable name for the textField UNLESS you are exporting for F5 for your own sake...
__________________
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
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


All times are GMT. The time now is 01:24 PM.

///
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.