How do I copy and paste columns from Sheet 1 to Sheet 2 which has the word "To" in its column headers?
Example, Column H Header = 12/2/2014 To 14/2/2014
I want to copy only these types of columns and paste it on another sheet.
PS I'm looking for a non-vba solution (if there is one) so any help would be much appreciated.
I've tried using this formula but nothing happens.
=IF(COUNTIF(Sheet1!A$1,"*TO*"),Sheet1!A2,"")
PS I'm using Excel 2013.
You can use Find formula that will return the number of "To" for that.
=IFERROR(FIND("To", A1, 1), "Did not found")
And in VBA you can use InStr that does almost the same operation.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.