Super Matrix Object Checkbox


I’ve got a Super Matrix Object with n rows in it.

Each row includes a checkbox.

When the checkbox is clicked, I can determine the row that was clicked and use matrixbuttonhelper to ensure the checkbox was clicked.

However, since the checkbox (a Super Object Data Button) is assigned a single variable, it seems like it’s not possible to have different values/states of a checkbox in different matrix rows.

Is this correct? Or is there “a trick”? :slight_smile:


– Mark

That is correct.

There are actually two issues here. The first, as you mention, is that the checkbox is linked to a single, fixed value. There’s no way to link it to different values depending on the location in the matrix.

There is also a second problem – items in a matrix are displayed, but they don’t really exist outside of being displayed. This means that you actually cannot click on them. When you click on a matrix, the matrix object gets the click event – it isn’t passed thru to the objects in the frame.

Between these two problems, you can’t fully use any clickable object in a matrix, this includes text editors, push buttons, data buttons, etc.

As for the specific issue of checkboxes, the only way to do this is to make a “fake” checkbox using a Super Flash Art object. You’ll need two images – a clicked and an unclicked checkbox, and then you can use a formula to display the correct image. You’ve already figured out how to use matrixbuttonhelper, you’ll have to write code with that to toggle the checkbox state. All of this is not just theoretical, I’ve definitely created databases that do that.

In Panorama X this is a bit easier. You still can’t fully use clickable objects in a matrix. However, the Panorama X data button object has a mode that allows the state to be determined with a formula, instead of being linked to a fixed field or variable. So you don’t need to use Flash Art. Also, you can now use the matrixclick statement instead of matrixbuttonhelper, it is quite a bit simpler to set up and more powerful. This is described in the Matrix class I taught in 2016, the video is online.

Hi Jim,

Yeah, thanks for the tip.

I have it working now. I just used a transparent button over a TDSO object.
When it’s selected, that TDSO toggles between “” and “√”.

Now, I need a “multisort” … Oh, look, there’s arraymultisort(). Unfortunately, on a large array (~9000 elements), it gets bogged down … everything else is screamingly fast! :slight_smile:


– Mark

Yes, that’s essentially the same as my flash art idea. However, I’m not sure what the transparent button is for. The matrix already is a transparent button. Any transparent button you put in the matrix frame is going to be ignored.

The transparent button lets me limit the click to a specific area within a matrix row, using matrixbuttonhelper. It also allows for multiple buttons in the row, should I need them … which I don’t right now. :slight_smile:

Got it.

You might be able to simplify a bit by assigning an object name to your Text Display object, and using that as the object id in matrixbuttonhelper. Then you won’t need the extra overlapping transparent button.

Yeah. I think I tried that, but the matrixbuttonhelper didn’t seem to recognize it.
However, I’d need to double-check because that test was many iterations ago … :smiley:

I wrote this statement/function several years ago - I’ll review it and see if I can speed it up.

Hi Michael,

Thanks for looking into this. Just so you know, I’ve already moved on and solved the problem differently. :smiley:

So, please do not waste time on this … unless you need it yourself! :slight_smile:

Thank you!

– Mark