I am using the code below to split one WorkSheet in to several tabs within the same WorkBook, based on the content of Column B. The macro automatically names each new tab, based on the text in Column B. The problem I have is that if the length of the text in Column B exceeds the 31 character limit, the sheet just gets named 'Sheet X', where 'X' is the next new sheet number, but in doing so, the data doesn't get copied to the sheet correctly.
Is there a way to 'truncate' and sheet names the code generates, so that the sheet uses the Excel maximum of 31 characters, when running the code. I don't know enough about vba to understand which lines of code are generating the names in the first place, I assume it is the section around 'Get a temporary list of unique values from vCol'. I can't truncate the text on the master sheet because this is used in various lookups.
Many thanks.
Bookmarks