![]() |
проверка данных
Простите за беспокойство у меня вопрос возник такой, поддерживает ли флаш регулярные выржения ( как в яваскрипт). Мне тут надо проверить введение данных в определённые поля и только пока одна мысль проверять если (textfielв1=="") то selection.SetFocus на textfielв1. но это коряво работает конечно. Можно как нибудь дезактивировать кнопку отправки данных как в ява ксрипт disabled пока не будут введены все данные?
Спасибо за помощь. |
_root.b_btn.enabled = false;
b_btn - твоя кнопка |
спасибо большое! сейчас попробую. а регулярные выр поддерживет?
|
не за что)
у меня в голове опилки))) ты поясни что такое регулярные выражения! |
Я во влеше новенькая но в ява скрипт можно задать переменную например var check_mail=/^.+\@.+\..+$/; для проверки правильности введения майла. Есть ди там символ @ или точка итп
|
именно такого во Флеше нет.
посмотри вот это в хелпе : String class String.indexOf() TextField class Удачи! |
спасибо, пойду почитаю.
|
бинин! почаму люди никогда не читают доку поставляемую с программой? конечно по ней неудобно изучать программу или получать первое представление о работе, но такие вещи как работа регулярных выражений вполне можно тама посмареть! итак! нажимаем Ф1 и в поиске вписываем regex и что же получаем?
Differences between ActionScript and JavaScript ActionScript is similar to the core JavaScript programming language. You don’t need to know JavaScript to use and learn ActionScript; however, if you know JavaScript, ActionScript will seem familiar. This manual does not attempt to teach general programming. There are many resources that provide more information about general programming concepts and the JavaScript language. The European Computers Manufacturers Association (ECMA) document ECMA-262 is derived from JavaScript and serves as the international standard for the JavaScript language. ActionScript is based on the ECMA-262 specification. For more information, see http://www.ecma-international.org/pu.../Ecma-262.htm). Netscape DevEdge Online has a JavaScript Developer Central site (http://developer.netscape.com/tech/j...ipt/index.html) that contains documentation and articles useful for understanding ActionScript. The most valuable resource is the Core JavaScript Guide. The Java Technology site has tutorials on object-oriented programming (http://java.sun.com/docs/books/tutorial/java/index.html) that are targeted for the Java language but are useful for understanding concepts that you can apply to ActionScript. Some of the differences between ActionScript and JavaScript are described in the following list: ActionScript does not support browser-specific objects such as Document, Window, and Anchor. ActionScript does not completely support all the JavaScript built-in objects. ActionScript does not support some JavaScript syntax constructs, such as statement labels. In ActionScript, the eval() function can perform only variable references. ActionScript 2.0, the latest version of the ActionScript language, supports several features that are not in the ECMA-262 specification, such as classes and strong typing. Many of these features are modeled after the ECMAScript 4 Draft Proposal currently in development by ECMA TC39-TG1 (see www.mozilla.org/js/language/es4/index.html), the standards committee in charge of the evolution of the ECMA-262 specification. ActionScript does not support regular expressions using the RegExp object. However, Macromedia Central does support the RegExp object. |
если честно я о том же)
тут каждый вопрос не только от новичка можно редиректить в хелп;-) |
народ я по англиски не понимаю. спасибо за помощь.
|
| Часовой пояс GMT +4, время: 00:58. |
Copyright © 1999-2008 Flasher.ru. All rights reserved.
Работает на vBulletin®. Copyright ©2000 - 2026, Jelsoft Enterprises Ltd. Перевод: zCarot
Администрация сайта не несёт ответственности за любую предоставленную посетителями информацию. Подробнее см. Правила.