Virtual button indexes start at 1, not 0. Also, you should load your "heman.jpg", "rainbow.jpg", and virtual button outside of the main loop and hide/show them instead.
Give this a try:
SetWindowTitle( "Don't let go!" )
SetDisplayAspect(16/9.0)
// set display properties
SetOrientationAllowed( 0, 0, 1, 1 )
left=CreateSprite(LoadImage("jumped.png"))
SetSpriteSize(left,20,-1)
SetSpritePositionByOffset(left,0,50)
SetSpriteOffset(left,0,GetSpriteHeight(left)/2)
AddVirtualButton(1,50,50,50)
SetVirtualButtonVisible(1,1)
SetVirtualButtonActive(1,1)
SetVirtualButtonImageUp(1,left)
SetVirtualButtonImageDown(1,left)
heman=CreateSprite(LoadImage("heman.jpg"))
SetSpriteSize(heman,100,100)
SetSpriteVisible(heman, 0)
rainbow=CreateSprite(loadimage("rainbow.jpg"))
SetSpriteSize(rainbow,100,100)
SetSpriteVisible(rainbow, 0)
do
if GetVirtualButtonState(1)=1
Rem make rainbow invisible
SetSpriteVisible(rainbow, 0)
Rem make heman visible
SetSpriteVisible(heman, 1)
else
Rem make rainbow visible
SetSpriteVisible(rainbow, 1)
Rem make heman invisible
SetSpriteVisible(heman, 0)
endif
Print( "I said hey!")
Sync()
loop
Sean