Suddenly I found that this css code in the app header is not creating alternating row colors in my tables. I didn’t change anything to affect it but somehow the nth row odd and even are not allowing colors there. When I look at it in Chrome developer tools, then highlight the row, I can see the color there but it is dimmed out. Here is the css code:
Just taking a quick glance at it, my guess is that this has to do with specificity. If you look at definitions in the datatables css file, the selectors for these things are probably more specific than what you’ve defined here and the browser is taking those instead of yours.
They have always worked before up until the latest release in 2022. According to the newsletter they are playing around with bootstrap stuff in order to get set for bootstrap 5 coming up. I think it might be affecting me. This code has worked for me.
If you’re saying that you’re encountering this in the latest beta (2023r1), this topic should have been created in the beta channel. If not, Xojo playing around with Bootstrap 5 should not be affecting any versions of the framework until it’s released. It’s going to be a non-trivial change IIRC.
Im not currently testing 2023r1. I ran into the problem with 2022 r4.1. After seeing that bootstrap was changing, I stripped out my bootstrap styles and created custom controls instead. But, certain parts of the listbox cannot be styled using style.value so instead I am using the app header.
I first noticed this problem immediately when I started using r4. As soon as I deployed to the cloud, my styles were missing… primarily listboxes and buttons, but other stuff too. So that’s when I decided to get rid of bootstrap. I deleted my bootstrap file and ran the program locally. The program ran without styles and it appears just as it did on the cloud. Somehow the cloud is not reading the bootstrap file as soon as I upgraded to r4. Im guessing because they are playing with the implementation of bootstrap, but that’s just a guess. As soon as I hit r4 my styles on the cloud stopped working and I can reproduce the bug by deleting my bootstrap.
Well that fixes the problem. I wonder why all the sudden my old code stopped working. I didn’t even know xojo was using the striped table. I tried using in the past and xojo didn’t recognize it. Weird. Oh well, problem solved.