View Single Post
  #4   Report Post  
Memphis
 
Posts: n/a
Default How to Copy the value of a cell to any given cell

Thank you Dave for posting your reply.
What I have done is:
Designed a monthly calendar Sun-Sat
the months are laid out like this:
JAN APR
FEB MAY
MAR JUN
so that upon print out one can see one whole semester.
Each cell has the day date on it (text)
At the right of Saturday's day date there is a blank cell where manually I
have to type in the day the person got paid that month
Currenthly I have placed a cmd button on top of the cell making it transparent
upon clicking it it copies the value of the cell it is on top of and pastes
it to the blank cell. (see code for cmd button on previous post).
So far I have only created the 1st semester for 2004 and it is taking
forever.
I am interested in knowing how by double clicking on the cell i could have
this done. please let me know.

Thank you


"Dave Peterson" wrote:

You want to process one row at a time--not all 365 rows all at once?

If yes, then I would use one button and put it in Row 1--then freeze row 1 so
that it's always visible.

Then you could select the row you want processed and then click the button.
(putting 365 buttons wouldn't appeal to me, either)

Private Sub CommandButton1_Click()
dim myRow as long
myrow = activecell.row
me.cells(myRow,"S").copy _
destination:=me.cells(myrow,"U")
application.cutcopymode = false
end sub

There's nothing built into excel that will catch your clicking--but you could
catch the doubleclick or rightclicking on a cell. If one of those appeals to
you, post back.



Memphis wrote:

This is what I typed in the VBA part of the cmd Button, I just hate the
thought of having to replicate this formula 365 times. Could there be an
easier way and also some way that will take less MB to create?

Private Sub CommandButton1_Click()
Range("S12").Select
Selection.Copy
Range("U12").Select
ActiveSheet.Paste
Application.CutCopyMode = False
End Sub

"Memphis" wrote:

How to copy the Value of a cell just by clicking on that cell and having its
value pop on another cell. For example:

A1=15, upon clicking on this cell, i would like the value to post on cell b1.

What I am doing is displaying a monthly calendar, to the right of the last
day of the week I have a blank cell where I currently type which day of the
week someone received a paycheck and then next to this cell I enter the value
of the paycheck.
It would be nice just to click on the date and have it copy to the blank
cell.
I tried creating command button overlayed on top of the cell with the value
and having it post the value to the blank cell, but my expertise is
challenged by lack of knowing more programing language.

Thank you


--

Dave Peterson