I have a custom control made from a canvas control (windows os).Though the mouse down event I have the image change…and change back to the original through the mouse up event. I do this for quite a few images in the control with a if/elseif (below is the mouse down event). The mouse down image is always the same name but with “_d” on the end. This custom control is just for myself and is specifically for this app so I realize it is not flexible enough to use for other apps. Is there a way where instead of using this big if/else that I can do something like Me.Backdrop = Me.Backdrop.tostring.+ “_d”? I know that syntax is not possible, from what I’ve read you can’t convert a string to a picture and load it like that. I was wondering if there was some other way. Thanks for any help you can provide.
if Me.Backdrop = button1 then
Me.Backdrop = button1_d
elseif Me.Backdrop = button2 then
Me.Backdrop = button2_d
elseif Me.Backdrop = button3 then
Me.Backdrop = button3_d
elseif Me.Backdrop = button4 then
Me.Backdrop = button4_d
end if