Quantcast
Channel: Excel Help Forum - Excel Programming / VBA / Macros
Viewing all articles
Browse latest Browse all 49945

If and If then macro or VLooup macro help

$
0
0
Hello all,

Total novice on Excel just warn you all :)
I've been searching a while for this and can't find anything.

The issue is following:

Everyday we import txt file in excel (using macro's) and rearrange the colums and sortings out. Also by macro. After we rearrange it, using subtotal counts, there is always 1 Cell empty next to the total.

Column A = Tag ID
Column B = Location
Column C = Description
Column D = Pallet ID
Column E = Date


What I want the macro to do is check in Column B if it is greater then 0 AND check Column C if the cell next to it is emty, then copy the data from C, D, and E under it.

For Example:

If B2>0 AND C2= Empty, Then Copy C1, D1, E1 to C2, D2, E2. and then check if B3>0 etc... If this makes sence.... And preferably if B21=0 or empty then the macro should stop.


Is this possible to create something like this?

Would really appreciate the help.



Regards,

Red

Viewing all articles
Browse latest Browse all 49945

Trending Articles