How do I switch between two images on the MIT app

Hi, I have a project where I have to switch between two images. mit app inventor. for example when i click on the cow sound it makes a sound and go to hen and when I click on hen it changes to cow

Just set the image picture on button click.

Use image picture block on button click, when cow button clicked set image picture to cow and when hen button clicked set picture to hen.

So when you click again on cow it will change picture.

Thank you! I have tried that, but it's not working. Can you please send a picture. Also I meant to be clicking on the the images or screen

open Image drawer, you will find all the blocks needed. Make sue you understand what function they can achieve.

Thank you!


blocks (20)
Just join the related blocks with them, then the cross sign will not show.

Try these blocks

1 Like

This is how I made my button(s) grow,shrink and change between two pictures. (you will have to download your own pictures btw)

Screenshot 2024-09-04 4.19.47 PM

When you click get bigger it will grow in size gradually and change the picture once. The get smaller button will gradually shrink the get bigger button and reset the picture. (reply back if this does not make sense.)