Enrique,
When a behavior is dropped onto a sprite, getPropertyDescriptionList is
called 2 times. The first, to initialize to default values, and then
again to display the dialog. This is why your checkParams is called
immediately after it is attached to your sprite. As far as I know,
getPropertyDescriptionList does not allow much in the way of data
validation.
You could try forcing users to enter valid data by using things like
sliders, checkboxes, and the #range property. Or, if you are feeling a
bit daring you could look into the runPropertyDialog handler and try to
cook up your own forms for user input. However, this could be more
trouble than it is worth.
What exactly are you trying to validate anyway? Maybe there is a way to
force users only to enter proper data.
Brian Romanko
Lead Developer - Neo/SCI Corporation
Member - Greater Rochester Macromedia User Group
-----Original Message-----
Hello again,
I'm posting again my question.
I would like to check some parameters that a behavior gets through a
getPropertyDescriptionList.
What I did is create a handler called checkParams and placed it inside
the
behavior. I call checkParams right before the return of the
getPropertyDescriptionList, after all the addProp.
My problem is that checkParams is called immediately after the behavior
is
attached to the sprite, before I had any chance to enter the values of
the
parameters.
How can I get Lingo to call checkParam after one clicks on the OK button
of
the parameter dialog?
Did I make myself clear?
Enrique
[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/LUJ/lingo-l.cgi To post messages to the list,
email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED])
Lingo-L is for learning and helping with programming Lingo. Thanks!]