I've got a whole bunch of cells containing arbitrary length arrays stored as semicolon-delimited strings, ranging in length from 1 to 65 entries, like:
- pcmsh15(232);pcmsh16(232);pcmsh17(136);
- pcmsh12(40);
- pcmsh12(40);
- pcmsh12(5);pcmsh15(20);
I want a way to sum up the numbers in the parenthesis in Excel 2010 without using VBA, keeping in mind that they are arbitrary length strings, each contained in their own cell.
I've currently got a VBA function that I wrote that sums the numbers in parenthesis, but it's slowing my spreadsheet down. I know I can use Excel's SUBSTITUTE function to turn the semi-colon delimited arrays into something resembling Excel's internal array format, like
="{"&SUBSTITUTE([@[data]],";",",")&"}"
But unfortunately, Excel won't parse that as an array in SUM or COUNTIF, only as a string. One workaround I found makes a named range that references the cell with a string-formatted array, but since I also have an arbitrary number of these arrays in cells, I can't go naming every single cell.
Is something like this possible in "pure" excel functions?
pcmsh15(232);pcmsh16(232);pcmsh17(136);in one cell or three?