> Nope - I didn't forget the me
>
> Here is the exact handler I have
>
> --------------------------------------------------------------
> on Change_Sprite_To_Appropriate_Note_Member me
>
>   case pInstrument_Icon_Number of
>
>     1: sprite(me.spriteNum).member="Instrument1_Note"
>
>     2: sprite(me.spriteNum).member="Instrument2_Note"
>
>     3: sprite(me.spriteNum).member="Instrument3_Note"
>
>     4: sprite(me.spriteNum).member="Instrument4_Note"
>
>   end case
>
> end Change_Sprite_To_Appropriate_Note_Member
> --------------------------------------------------------------
>
> Even though it works fine now replacing me.spriteNum with the
> currentSpriteNum, I am still curious as to why it doesn't work with
> me.spriteNum!


I just pasted your code into a behaviour, Using a mouseDown even to trigger
the Change_Sprite_To_Appropriate_Note_Member handler, and it worked fine! So
it's not because you don't specify member("name").

Have a look at your script properties - maybe you have a wrong script type?
(although I doubt that's it, it's worth checking)

How are you calling the handler? If you're calling it from the same script,
you shouldn't forget to specify the me there as well:

me.Change_Sprite_To_Appropriate_Note_Member()
or
Change_Sprite_To_Appropriate_Note_Member me
but not
Change_Sprite_To_Appropriate_Note_Member



PS: If you declare spriteNum as a property, you won't need to use
me.spriteNum all the time.
Even better, make a shorthand variable: mySprite = sprite (me.spriteNum)
and then you can type mySprite instead of sprite(me.spriteNum)
Even better then that: pMember = sprite(me.spriteNum).member and then
pMember="Instrument1_Note"

Hope any of this helps


Karina Steffens,
Multimedia Designer/Programmer

Martello Media Ltd.
4 Islington Avenue
Sandycove
Co. Dublin

Tel: +353 1 2844668
Fax: +353 1 2803195
http://www.martellomm.ie








[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!]

Reply via email to