Yes Kevin, my thoughts exactly for that particular example. But I have to say your solution s perfect for a different problem I had where the text is aligned to the right.
Because when I dont need this extra text, i need the last part of that line to move back into proper position so I added an if layer active else statement looking for that other layer to be active or not. Even though we technically never see that actual layer, I just left the opacity at 0 and it works as a switch. Works like a charm, here is the exact code thanks to you;
on source text
if(thisComp.layer(“small text”).active) value + ‘ ‘ + thisComp.layer(“small text”).text.sourceText else value
on range selector 1 start
txt1 = text.sourceText ;
txt2 = thisComp.layer(“small text”).text.sourceText ;
if(thisComp.layer(“small text”).active) (100 – 100 * txt2.length / txt1.length ) else 100
on tracking amount
if(thisComp.layer(“small text”).active) -17 else 0