Hi All,
I have zero knowledge in VBA, tried to find a solution to my problem with functions, unfortunately without success.
I have an Excel sheet that contains text values, for example:
Run for 5 mins at < 70% of a VAR> pace
It could also contain < VMA70> < VMA/0.7> or < VMA>/0.7, but I guess that it's just a matter of "replace all".
I would like to replace “< VAR>” by the content of a cell and compute it, for example above multiplied by 70%.
Sometimes such a tag will even appear twice in 1 cell, and there might be carriage returns in cells.
Problem is that the cell is text. I believe I actually need to:
First replace the cell by something like:
=”Run for 5 mins at “&< 70% of a VAR>&” pace”
Then probably replace < 70% of a VAR> by < VAR>*70% to get:
=”Run for 5 mins at “&< VAR>*70%&” pace”
To finally replace < VAR> by a certain cell, let’s say H4, and force its evaluation:
=”Run for 5 mins at “&H4*70%&” pace”
If H4="05:10" the final text should then be ”Run for 5 mins at 07:23 pace”
Note that I will also have to encode this in "mm:ss", so I will need something like TEXT(myresult,"mm:ss"), but I believe that won't be too much of an issue.
Could you please help me understand if my reasoning is correct, and how I could proceed with such replacements to fix about many cells in 1 go?
I will have about 50 cells to do in about 40 Excel tabs or files.
Enclosed is my file for reference.
Thanks a lot for your help as always!
Bookmarks