In one go?
alert ("Not possible");
You need to go over each possible object, and test every single property that may have a color.
(Single characters are also objects, but fortunately checking these is as simple as doing a global find operation with your color in the fillColor or strokeColor parameter. Then repeat, with your color in the underlineColor parameter, and again for underlineGapColor. Then repeat for ruleAboveColor and ruleAboveGapColor, and again for a possible rule below.
You can do the same for fill and stroke of simple objects, but I'm not too sure how that works when your object may be grouped. There is no find-in-table function, so tables have to be checked one cell at a time, for all possible colored items.)
Thanks, Jongware. If your are writing this then I have to except it.
Thanks for your time and support.
But I'm not writing it ...
Did you happen to see getZinger's suggestion in one of the other threads you posted about this?