![]() |
Updating (Adding Rows) To A Second Worksheet
I've got a value (a city name) in cell a1 in Sheet2 of Book2.xls. Want want to do is open a second workbook (Book1.xls), find the value i the third column of sheet1 and insert a blank row after the entry. Any help is great appreciate ----------------------------------------------- ~~ Message posted from http://www.ExcelTip.com ~~View and post usenet messages directly from http://www.ExcelForum.com |
Updating (Adding Rows) To A Second Worksheet
jd,
Sub TryNow() Dim myVal As String Dim myCell As Range myVal = Workbooks("Book2.xls"). _ Worksheets("Sheet2").Range("A1").Value Workbooks.Open "C:\Excel\Book1.xls" Worksheets("Sheet1").Activate Set myCell = Range("C:C").Find(myVal) myCell(2).EntireRow.Insert End Sub HTH, Bernie MS Excel MVP "jdcollins21" wrote in message ... I've got a value (a city name) in cell a1 in Sheet2 of Book2.xls. Want I want to do is open a second workbook (Book1.xls), find the value in the third column of sheet1 and insert a blank row after the entry. Any help is great appreciated ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~View and post usenet messages directly from http://www.ExcelForum.com/ |
All times are GMT +1. The time now is 02:16 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com