This binding converter would allow something to be true/false, if the source contains ANY info or not. This would be very helpful for certain things to happen if an Excel cell is blank. Or if the cell contains something.
Here’s a simple example that I run into ALOT:
Often when working with a data set in Excel, there will be some columns that contain information in the row, and some that do not. For example, if I’m going to show a list of something I might have ListHeader, ListItem1, ListItem2, ListItem3. But not all the records may have 3 items in the list. Some may have two, and some might have 1.
I only want bullet points to show up next to items in the list that are NOT blank. So I could bind the visibility of the bullet point to the list item, and set the converter to be “Not Blank” So that means visibility is TRUE when the current excel cell is Not Blank…ie; contains anything.
I know this can be done by adding a column for EVERY list item called Show bullet with True/False. But that gets redundant to have a column for every list item. Also, it doesn’t account for dynamic data…which means you’d need to manually label true/false for each row yourself.
My example is simple, but there are many more uses…and more complex things can be done. For example, setting Toggle buttons to check/uncheck based on data that is or isn’t there - opening up your whole list of actions.
This binding converter would be another step forward to dynamic elements that are conditional to the data being shown.