public override string TransformRange(string stringToTransform, string commandContent, Dictionary <string, string> variables) { var split = commandContent.Split(',').ToList(); string variableName = split[0]; string textToSearchFor = split[1]; bool contained = stringToTransform.Contains(textToSearchFor); return(StringTemplate.CreateSetVariableBlock(variableName, contained ? "1" : "0") + stringToTransform); // reprocess with this variable set at the beginning }