# OnPress...ease into place

**URL:** https://forum.kirupa.com/t/onpress-ease-into-place/198118
**Category:** flash
**Created:** [August 22, 2006, 4:35pm UTC](https://forum.kirupa.com/t/onpress-ease-into-place/198118 "2006-08-22T16:35:57Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![haider](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@haider](https://forum.kirupa.com/u/haider)
#### Post date: [August 22, 2006, 4:35pm UTC](https://forum.kirupa.com/t/onpress-ease-into-place/198118/1 "2006-08-22T16:35:57Z")

</div>

I would like it so that when I click the “envelope” button… the actionscript makes the “businesscard” movieclip slide into the same x and y position as the “cardopen” movieclip.

my code isn’t working:

on(press){  
businesscard.\_y-=(businesscard.\_y-cardopen.\_y)\*25  
businesscard.\_x-=(businesscard.\_x-cardopen.\_x)\*25  
}

* * *

though if I type the code without the \*25  
it works … it just snaps the card into position without any easing

* * *

any help please?

Thanks
