Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default XL2007 .CodeName bug when copying sheet

My application uses .CodeName property to identify XL sheets.
When copying a sheet within a workbook the new sheets gets the same CodeName
plus Index.
This fails in XL2007 SP1.

Steps to reproduce bug:

1. Create new workbook
2. Modify .CodeName property of sheet 1 (e.g. test) in VBE
3. Save workbook
4. Close workbook and open it again (don't start VBE (F11))
5. Copy sheet 1
6. Check .CodeName property of copied sheet
7. BUG: CodeName is not e.g. test1

Does anybody knows a workaround to this problem?

TIA
Reinhard

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,510
Default XL2007 .CodeName bug when copying sheet

My test seem Ok. Codename was test1.

--
Regards,

OssieMac


"Reinhard Thomann" wrote:

My application uses .CodeName property to identify XL sheets.
When copying a sheet within a workbook the new sheets gets the same CodeName
plus Index.
This fails in XL2007 SP1.

Steps to reproduce bug:

1. Create new workbook
2. Modify .CodeName property of sheet 1 (e.g. test) in VBE
3. Save workbook
4. Close workbook and open it again (don't start VBE (F11))
5. Copy sheet 1
6. Check .CodeName property of copied sheet
7. BUG: CodeName is not e.g. test1

Does anybody knows a workaround to this problem?

TIA
Reinhard


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default XL2007 .CodeName bug when copying sheet

Hi OssiMac,

you have to copy the sheet imediately after opening workbook (Point 4.) .
Don't start VBE (F11) before.
If VBE is stared before copying works correctly!?
I tried it many times with different file formats (2007 and 2003). Always
the same behaviour.

Reinhard


"OssieMac" schrieb im Newsbeitrag
...
My test seem Ok. Codename was test1.

--
Regards,

OssieMac


"Reinhard Thomann" wrote:

My application uses .CodeName property to identify XL sheets.
When copying a sheet within a workbook the new sheets gets the same
CodeName
plus Index.
This fails in XL2007 SP1.

Steps to reproduce bug:

1. Create new workbook
2. Modify .CodeName property of sheet 1 (e.g. test) in VBE
3. Save workbook
4. Close workbook and open it again (don't start VBE (F11))
5. Copy sheet 1
6. Check .CodeName property of copied sheet
7. BUG: CodeName is not e.g. test1

Does anybody knows a workaround to this problem?

TIA
Reinhard



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,510
Default XL2007 .CodeName bug when copying sheet

Hi Reinhard,

Your are right. Also you can copy as many times as you like and it is still
Sheet1, Sheet4, Sheet5 etc. (I had 3 sheets to start with). After opening and
closing VBA editor then it will show Test1,Test2 etc.


--
Regards,

OssieMac


"Reinhard Thomann" wrote:

Hi OssiMac,

you have to copy the sheet imediately after opening workbook (Point 4.) .
Don't start VBE (F11) before.
If VBE is stared before copying works correctly!?
I tried it many times with different file formats (2007 and 2003). Always
the same behaviour.

Reinhard


"OssieMac" schrieb im Newsbeitrag
...
My test seem Ok. Codename was test1.

--
Regards,

OssieMac


"Reinhard Thomann" wrote:

My application uses .CodeName property to identify XL sheets.
When copying a sheet within a workbook the new sheets gets the same
CodeName
plus Index.
This fails in XL2007 SP1.

Steps to reproduce bug:

1. Create new workbook
2. Modify .CodeName property of sheet 1 (e.g. test) in VBE
3. Save workbook
4. Close workbook and open it again (don't start VBE (F11))
5. Copy sheet 1
6. Check .CodeName property of copied sheet
7. BUG: CodeName is not e.g. test1

Does anybody knows a workaround to this problem?

TIA
Reinhard




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
XL2007: Copying worksheets between workbooks Josh Sale[_3_] Excel Programming 0 November 27th 08 12:46 AM
Hide sheet via codename [email protected] Excel Programming 3 September 13th 06 08:28 PM
Use of sheet codename in codeline - How? Jim May Excel Programming 3 July 1st 06 04:24 PM
change sheet codename Gary Keramidas Excel Programming 4 March 5th 06 12:54 AM
Selecting a sheet by codename Dr.Schwartz Excel Programming 3 September 3rd 04 02:15 PM


All times are GMT +1. The time now is 02:16 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"