LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 39
Default Delete in different worksheets and workbooks

Hi Experts,

I am trying to repeat the procedure below (delete "Back To Contents" in 45
sheets and 11 workbooks), but I can not find the right code. I am doing with
For next, but is deleting that only in the Active worksheet.

Thanks

Sub deleteBackToContents()

n = Cells(Rows.Count, "A").End(xlUp).Row
For i = n To 1 Step -1
With Cells(i, "A")
If .Value = "Back To Contents" Then
.EntireRow.Delete
End If
End With
Next
End Sub
 
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
Copy/ move selected data from workbooks to seperate worksheets or workbooks Positive Excel Worksheet Functions 1 August 30th 07 04:54 PM
How to delete duplicates between workbooks? Jay Excel Worksheet Functions 1 January 23rd 07 03:06 PM
How to delete duplicates between workbooks? Jay Excel Worksheet Functions 0 January 23rd 07 02:58 PM
Simultaneous rst.AddNew and rst.Delete from 2 Workbooks Trip[_3_] Excel Programming 0 December 27th 06 08:50 PM
Delete columns simultaneously in several different workbooks [email protected] Excel Discussion (Misc queries) 1 August 9th 06 05:51 PM


All times are GMT +1. The time now is 06:04 AM.

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

About Us

"It's about Microsoft Excel"