VBA to copy and paste data (selections based on a string)

Wunderbarre

New Member
Joined
Jan 4, 2019
Messages
2
Hi gurus,

I have a worksheet that updates dynamically. The IDs comes in Column H and the data in columns J,K, and L. I need to find all the IDs that have the letters "AC" in them and copy data from J, k, L columns ( of the same row as the ID with AC). After copy, it has to insert the data as rows in another table in Columns AK(ID column) Row 38 onwards and columns AM, AN and AO (Row 38 onwards). The screenshots show the requirements.

Thanks.
9

33cnbyw.png


2dhdy1e.png


Note that there will be data after the pasted Rows.
 

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)

alansidman

Well-known Member
Joined
Feb 26, 2007
Messages
7,593
Office Version
  1. 365
Platform
  1. Windows
Are you pasting to the same sheet? Or a different sheet?

What does this mean?
Note that there will be data after the pasted Rows.
Does it mean that the pasting requires that new rows be inserted at Row 38 or that the data is pasted into the next empty row after row 38. Please clarify what you mean.
 
Upvote 0

Forum statistics

Threads
1,195,827
Messages
6,011,820
Members
441,648
Latest member
Bigjohnj

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top