Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
A little help with some code please.
What I am trying to do: I have a bunch of data on SHEET1. If the value of A7 <= 0 I would like to have a button show up in P7 that says “MOVE”. If you click that “MOVE” button it will cut B7 through H7 from the sheet and append it to SHEET2. Then go back to SHEET1 and (I guess) move up B7 through H7. The problem is there are formulas in A, I, J, K, L, M, and N. so I just cant CUT the whole line as it will mess up all my formulas. Thank you very much for your help in this matter. Ken -- sungen99 ------------------------------------------------------------------------ sungen99's Profile: http://www.excelforum.com/member.php...fo&userid=9144 View this thread: http://www.excelforum.com/showthread...hreadid=537233 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
A little help with some code please.
I do not know where you want paste data?,
but taste this: (I think, that you have already button). Private Sub CommandButton1_Click() Application.ScreenUpdating = False Range("B7:H7").Select Selection.Copy Sheets(2).Select Sheets(2).Range("B7").Select Sheets(2).Paste Sheets(1).Select Application.CutCopyMode = False Selection.Delete Shift:=xlUp Range("B7").Select Application.ScreenUpdating = True End Sub Kind Regards, Andrzej sungen99 napisał(a): What I am trying to do: I have a bunch of data on SHEET1. If the value of A7 <= 0 I would like to have a button show up in P7 that says �MOVE�. If you click that �MOVE� button it will cut B7 through H7 from the sheet and append it to SHEET2. Then go back to SHEET1 and (I guess) move up B7 through H7. The problem is there are formulas in A, I, J, K, L, M, and N. so I just cant CUT the whole line as it will mess up all my formulas. Thank you very much for your help in this matter. Ken |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
split post code (zip code) out of cell that includes full address | Excel Discussion (Misc queries) | |||
Drop Down/List w/Code and Definition, only code entered when selec | Excel Worksheet Functions | |||
do anybody have a sample code for executing excel macro from vb code?<eom | Excel Programming | |||
stubborn Excel crash when editing code with code, one solution | Excel Programming | |||
option buttons run Click code when value is changed via VBA code | Excel Programming |