View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Greg Koppel Greg Koppel is offline
external usenet poster
 
Posts: 79
Default Separating workbook name from extension

filename = "test.xls"
newName = Left(filename, len(filename) - 4) & vbTab & Right(filename, 4)

"William Francis" wrote in
message ...
Hi guys,

Can anyone please let me know whether any code exists which separates a
workbook name from its extension (e.g. a spreadsheet named "test.xls"

would
be separated into "test" and ".xls")?

Thanks in advance,
Will