Search : in
By :

Compare and update excel sheet

Last answer on Jul 16, 2009 11:38:15 am BST ujo, on Jul 16, 2009 4:56:31 am BST 
 Report this message to moderators

Hello,
I have got two excel sheets one master sheet that gets updated everymonth with the new employees joining that month. the other excel sheet needs to pull the data i.e names of employees only who are not existing in it. ie new entries from the master sheet needs to be updated in the later sheet. Please help
Regards
Ujwal

Best answers for « Compare and update excel sheet » in :
How to compare 2 excel sheet and combine uniq data? Show How to compare 2 excel sheet and combine uniq data? Issue Solution Note Issue I have 2 excel sheets , A and B. There are redundant data in both sheets as well as uniq. All i want is to combine both with no redundant records. (A+B...
Avoid duplicates in Excel ShowAvoid duplicates in Excel In order to avoid duplication when encoding in a column from an excel sheet: take the conditional format on the first cell under the headings (eg A2) choose the following formula:...
Create an Attendance Report with Excel sheet ShowCreate an Attendance Report with Excel sheet Issue Solution Issue In the case you want to create an attendance report with Excel , here below you will find a nice example: Consider that your report will have the following...
How to freeze a row in an excel sheet ShowHow to freeze a row in an excel sheet To freeze a line in an excel sheet, for example line 1: Select line 2. Go to menu Window and select Freeze panes.

1

venkat1926, on Jul 16, 2009 10:53:35 am BST
  • +1

Sheet 1 is master sheet and sheet 2 is the other sheet .

modify the macro to suit your

Sub test()

Dim rng1 As Range, c1 As Range, cfind As Range, x As String
On Error Resume Next
With Worksheets("sheet1")
Set rng1 = Range(.Range("a2"), .Range("a2").End(xlDown))
For Each c1 In rng1
x = c1.Value
'MsgBox x
With Worksheets("sheet2").Columns("A:A")
Set cfind = .Cells.Find(what:=x, lookat:=xlWhole)
If cfind Is Nothing Then
GoTo line1
Else
GoTo line2
End If
End With
line1:
'MsgBox c1.Value c1.EntireRow.Copy
With Worksheets("sheet2")
.Cells(Rows.Count, "a").End(xlUp).Offset(1, 0).PasteSpecial
End With
line2:
Next c1
End With
Application.CutCopyMode = False

End Sub

Reply to venkat1926

2

 ujo, on Jul 16, 2009 11:38:15 am BST

Hey venkat this is simply great ..

thanks a ton

Ujo

Reply to ujo