Highlighting current row
Is it possible to have the current row you're working in highlighted with some color?
Yes, have you done a search for the topic on the forum?
The answer is to reverse what you want. Set the background on all the fields to the color you want as your highlight (for example yellow). Then you would attach conditional formatting to every field in your list. The conditional format would be Formula (and just type a 1) and set the background to the color you want fields to be as their standard background color (for example white).
You can select one field and then Edit > Select All (which will automatically select all same-type objects, in this case fields) and set the background to yellow at one time and also set the conditional format at one time since it will be the same formula for all fields.
Wouldn't having to set this for every field cause performance issues, especially if it is conditional? I have close to 2000 rows and 70 columns. Scrolling through rows either horizontally or vertically is already very sluggish. I don't want to set background and then decide it is just too slow, only to find out FM has left pieces of the background setting in every field.
We use it in several solutions. It isn't like it needs to evaluate. The evaluate is simple Boolean true. We scroll in table view through 285,000 records with no hesitation whatsoever. Any other method will be certainly be slow.
Does the highlighting only work for the field you are in? Or the entire row?
Guess I need to start another post about the degraded performance I see.
"Does the highlighting only work for the field you are in? Or the entire row?"
The highlighting works on all fields except the one you land in which is why it is considered 'reversed' and several top Developers use the process - it is pretty standard practice to highlight the entered field this way.
I would bet that the sluggishness results from something else. :^)
ok, thanks. Not really what I'm after. I'd instead like the entire row I'm in to highlight...but sounds that isn't possible.
It is possible, but takes a different approach that you will need to test for performance hits. It's worked well for me, but I haven't tried it on a list view with 100's of thousands of records to list, nor have I tried it with FileMaker GO on an iOS device.
Put a layout object behind all your other layout objects. This can be a button with Do Nothing specified, a block of layout text with just a space entered as its text or even an empty global field where you set behavior to deny access to the field.
Given it this conditional format expression:
$$RecordID = Get ( RecordID )
Use the OnRecordLoad layout script trigger to run this script to update $$RecordID:
Set Variable [$$RecordID ; value: Get (RecordID ) ]
Now, whenever you click on or into a field on a different record, or use the "book" control at the top to change records, the newly current record's background "highlihts" with the specified fill color that you selected for this layout object's conditional format.
Have you tried that, Phil? I did and I couldn't make it work. You might want to check it.
Here is how I handle it and, Brett, I apologize that I mis-read your opening post and thought you wanted fields to highlight as moving through the fields (it was very early for me). To highlight a row in list view:
Create a script called Freeze Window with only one script step: Freeze Window. Attach it under Layout Setup > Script Triggers to OnRecordLoad. Create your rectangle and place it on the row and send to back using Arrange. Attach conditional formatting to it with:
$$selectID = table::ID
The bad thing about using a text box with a space in it is that, in layout mode, if you accidently click into it and then leave, it will delete the text box and your highlight; best to use a button with no formatting and don't type into the button. Then, in your header, type this text: I declare variables. Make it red so it stands out. Right-click it and set this conditional format:
Let ([ $id = table::ID ; $$selectID = $id ; ] ; Get ( WindowMode ) < 4 )
... you will select no formatting in the sections below. This is only to trigger the merge variable. You can add other variables that you wish in the Let() as well. This technique learned from Comment (Michael Horak). It uses conditional formatting to run calculations on a layout (similar to how Access uses calculations). Anyway ... I side-track ... now select this text and Arrange > Send to Back. It must always be first (on bottom) of stacking order.
And yes, it should be native in FM.
Thanks for the heads up LaRetta.
I use that method in my Known Bugs List database to make a field highlight. I referred to it when I made that last post.
I went back and looked at the script again and see I left out a step. It should work as:
Set Variable [$$RecordID ; value: Get (RecordID ) ]Refresh window 
Yep, it works; I should have thought of that - I just never code the variable I want to fire within a script.
On large record sets, you will find that Freeze Window causes less flash. I like to use the text box because I include a lot of calculations, text displays and functions within the one 'I declare variables' so it becomes more dynamic. By coding the request within the script, the script becomes more limited.
All is good but none are as good as providing us the ability natively and to have TRUE record indicators instead of the small black bar. :^)
Retrieving data ...