Compare A Backdrop Against Another

I’m trying to do this:

if Answer.cnvColor(idx).Backdrop = Guesses.cnvGuess(idx).Backdrop then

…and it’s never going into that block, even when I look in the debugger and see that the same picture is in each control.

In another part of my app I’m doing this:

if cnvGuess(x).Backdrop = BallPlaceholder then

…and that’s working fine.

Is there a trick to comparing backdrops that I haven’t grokked?

Jay

PS - This is for a desktop app on Mac.

Answer.cnvColor(idx).Backdrop is an object pointer, not a comparable value
so each backdrop is most likely a pointer to a reference inside “answer” and inside “guesses”
so the will never be equal, even if you loaded the same exact file

So I would figure out a way to carry along another value (say an Integer) that you CAN compare

Use the interface to display data, not store it.

I don’t know enough about your app to make a better recommendation.

Thanks so much for the help. I reworked things so I’m dealing with numbers, and then those numbers can be used as an index into an array to show the actual pics, so it’s all good now. (If you overlook the spaghettiness of the resulting code. I blame Paul – Friday to Friday just isn’t long enough!)

Jay