Set 2 different Images to button Field as Caption/Icon to toggle between images
I have a button field which cycles through SELECT > MALE > FEMALE option for gender .
Below is the script:
if (event.target.buttonGetCaption()=="SELECT")
{event.target.buttonSetCaption("MALE");}
else if (event.target.buttonGetCaption()=="MALE")
{event.target.buttonSetCaption("FEMALE");}
else if (event.target.buttonGetCaption()=="FEMALE")
{event.target.buttonSetCaption("SELECT");}
I want instead of text MALE or FEMALE.. i want to put there small icon of male and female don't want to use layer visibility or two buttons (hide/show)....... is it possible to put two different icons in the same button and cycle through.
Thanks