Hi i have a table of data, where there is going down a series of parameters, and going across various readings for these parameters, now i am trying to format the data and move it into another workbook, and i was wanting to use a for loop to search for a string i.e. parameter name and from this activate code to move certain bits from that parameter row into another a workbook
[vba]Dim MyString As String
Dim c As Object
Dim i As Long
MyString = "Leq"
For Each c In Sheets("Original").Range("A1:A65536").Cells
If c = MyString Then i = ActiveCell.Row
Range("D" & i, "N" & i).Select
Selection.Copy
Windows("NA28 Thirds To Table.xls").Activate
Sheets("NA28 Table Oct Summary").Select
Range("O" & i).Select
ActiveSheet.Paste
Windows("mybook").Activate
Next
End Sub[/vba]
This is what i have at the minute but it doesn't seem to work, i'm not a complete novice programmer but am when it comes to VBA.
thanks in advance, Dan.