Macro for allocations and movement

Howza297

New Member
Joined
Sep 18, 2012
Messages
1
Hi Guys,

I have been puzzling over trying to create a macro for this. I am pretty new to VBA, and so this is probably out of my league in terms of programming :confused:

I need a looping macro to take the first value from Q (i.e Q2), then search down the other values in column Q for its opposite value (so that the net is exactly nil). If the exact opposite is found, i need the macro to cut both rows that these cells sit on, and paste them to another sheet called "allocations" underneath eachother. If it does not find a match in column Q, then move onto the next value (i.e Q3)

Thanks in advance to any help that anyone can give me, I will truely appreciate it :)
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
Hi, patel45,

if cell value of Q2 is 2, then search for -2 - it´s as easy as that.

Ciao,
Holger
 
Upvote 0

Forum statistics

Threads
1,216,036
Messages
6,128,432
Members
449,452
Latest member
Chris87

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
Back
Top