Renaming sheets

A

Adri

I use the macro "Testfile(6)" form http://www.rondebruin.nl/copy3.htm.
It copies the first sheets coorrect. The macro also should rename the sheet
the same as the workbook name.
Some names are correctly renamed, others not.
What causes this and how can I fix it?
 
R

Ron de Bruin

Hi Adri

Can you give example

If the name already exist the on error will avoid a error
and the sheet will not be named for example
 
A

Adri

Hello Ron,
The sheets taht are not renamed correctly get names like rapp(15), rapp(16).
The files in the directory have all different names. I copy in a workbook
with only one sheet. In my opinion the name can't already exist.
Adri

Ron de Bruin wrote:
| Hi Adri
|
| Can you give example
|
| If the name already exist the on error will avoid a error
| and the sheet will not be named for example
|
|
| || I use the macro "Testfile(6)" form
|| http://www.rondebruin.nl/copy3.htm.
|| It copies the first sheets coorrect. The macro also should rename
|| the sheet the same as the workbook name.
|| Some names are correctly renamed, others not.
|| What causes this and how can I fix it?
||
|| --
|| Kind regards
|| Adri
 
A

Adri

Ron de Bruin wrote:
| Can you send me a test workbook Adri
|
I find the solution. The length of the files that did not rename well, were
bigger then 31 signs.
I renamed them and everything went ok.
Thanks,
Adri
 
Top