Hi All,
i Want suggestions for this , i am having 2 workbooks one is excel another one is macro, we have to take the data from excel , filter it in the macro file. after filtered data if condition is met (specific text contains one row), we have to copy some specific data in the row. what my problem is after filtering the data that display 2 or 3 rows for that filter , if condition check the rows if sentence condition is met copy specific rows , not all row values only preferred rows data only we have to paste the excel .
i tried this code but its not getting
d = Worksheets("Template").Range("G" & Rows.Count).End(xlUp).Row
Dim Text As String
Text = Workbooks("Output file.xlsm").Sheets("Sheet2").Range("B" & i).Value
If Text < 100 Then
If InStr(Range("G").Value, "<100") > 0 Then
Range("D" & ",E").Copy
ActiveSheet.Rows(i).Select
Rows(i).Activate
Worksheets("Template").Rows(i).Copy
Sheets("Sheet2").ActiveSheet.Range("D2:F1000000").PasteSpecial Paste:=xlPasteAll
Application.CutCopyMode = False
End If
End If
i Want suggestions for this , i am having 2 workbooks one is excel another one is macro, we have to take the data from excel , filter it in the macro file. after filtered data if condition is met (specific text contains one row), we have to copy some specific data in the row. what my problem is after filtering the data that display 2 or 3 rows for that filter , if condition check the rows if sentence condition is met copy specific rows , not all row values only preferred rows data only we have to paste the excel .
i tried this code but its not getting
d = Worksheets("Template").Range("G" & Rows.Count).End(xlUp).Row
Dim Text As String
Text = Workbooks("Output file.xlsm").Sheets("Sheet2").Range("B" & i).Value
If Text < 100 Then
If InStr(Range("G").Value, "<100") > 0 Then
Range("D" & ",E").Copy
ActiveSheet.Rows(i).Select
Rows(i).Activate
Worksheets("Template").Rows(i).Copy
Sheets("Sheet2").ActiveSheet.Range("D2:F1000000").PasteSpecial Paste:=xlPasteAll
Application.CutCopyMode = False
End If
End If