Adding to data to a list

M

mushy_peas

I want to make log, ie add blocks of data to main block. So far i have
very crude method of moving the main block down a few spaces, the
copying the new data to the top. then again when theres more. this i
no way perect.

I would like the be able to copy the new data to the bottom of the lis
via some incremental method, but i cant find one.

Any suggestions welcomed
Cheers
 
D

Don Guillett

untested but try assigning to a button or worksheet change event.
To copy instead of move just change the word move to copy.

sub movetobottom()
x=cells(65536,activecell.column).end(xlup).row
activecell.entirerow.move cells(x,activecell.column)
end sub
 
G

Gord Dibben

mushy

Not sure what you need here.

CRTL + downarrow will take you to the bottom of any contiguous block of data
in a column.

Copy your new block and select a cell in the column you want to paste into
then hit CRTL + downarrow then downarrow by itself and Paste.

After that you can Sort if you wished.

More details would be in order if this is not what you mean.

Gord Dibben XL2002
 
M

mushy_peas

Thanks for the quick replies. much appreciated.

I done a simple EPOS, fancy till if u like. I want to store th
transactions. I have made a macro that finishes the transactiion an
prints the reciept. What i want also is to automatically store th
details, ie the time, items and the quantity.

What i have done so far is got it copy the data onto another shee
called "log". Then after the next transaction the data in the log shee
is moved down by X rows and the new data copied into the vacant space
This all happens again after the next transaction.

This is prob OK for small number of transaction. Also i see othe
probs. its prob better to add the data to the end of the log, so there
no guessing
:
 
D

Don Guillett

OOPs
Change row to row+1 and MOVE to CUT

sub movetobottom()
x=cells(65536,activecell.column).end(xlup).row+1
activecell.entirerow.CUT cells(x,activecell.column)
end sub
--


--
Don Guillett
SalesAid Software
(e-mail address removed)
Don Guillett said:
untested but try assigning to a button or worksheet change event.
To copy instead of move just change the word move to copy.

sub movetobottom()
x=cells(65536,activecell.column).end(xlup).row
activecell.entirerow.move cells(x,activecell.column)
end sub
 
M

mushy_peas

Don

that worked. not exactly what i was after, but effective none the less
Is it possible to move more than i row?
 
D

Dave Peterson

Modifying Don's code:
Option Explicit
Sub movetobottom()
Dim x As Long
x = Cells(65536, ActiveCell.Column).End(xlUp).Row
ActiveCell.Resize(13).EntireRow.Cut Cells(x + 1, 1)
End Sub

The Resize(##) gives the number of rows to cut.

And I changed the destination column to 1 (from activecell.column).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top