View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
bb pcv[_2_] bb pcv[_2_] is offline
external usenet poster
 
Posts: 1
Default Paste upon click

I could not get this code to work.
Maybe a fuller explaination of what I'm trying to do will help.
I have 10 employees who see clients throughout the day. Appointment lengths
are predicated on the number of programs clients are requesting. The
worksheet has the employees in Column A and the times in Columns B:AS. Each
cell in the appointment grid represents 15 minutes. At the top of the grid,
I've named ranges (a, b, c, etc) that represent different lengths of
appointments, and color coded the ranges so that the different appointment
types are readily distinguishable when pasted into the main grid. I have
placed a Forms Label over each of the appointment types and attached a macro
that slects the range and places it on the clipboard (Range("A").select
Selection.Copy)
The user (Receptionist) clicks on the appropriate appointment type -
launching the macro - and then places the cursor in the intersection of time
and employee. To paste the selection, they must use the keyboard shortcut or
right click.
I'd like to have them select the range with one click and then paste with
another.

Thanks for any help you can give...

"JLGWhiz" wrote:

This assumes the label is from the Control Toolbox and is on the same sheet
as the named cell, and that the receiving cell is on the same page. Copy
both subs to the sheet code module. Click the label, then click a cell.
Don't forget to save the file to keep the code.
You can name the label and update the code, in case you have more than one
label.

Private Sub Label1_Click()
Range("More_Time").Copy
End Sub

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Target.PasteSpecial xlPasteValues
End Sub



"bb pcv" <bb wrote in message
...
I would like to write a macro, to be attached to a label, that upon
clicking
the label, would put the named range on the clipboard, and then paste the
range at a cell in the worksheet with another click.
current code:
Sub More_time()
Range("More_Time").Select
Selection.Copy
End Sub
would like to paste by clicking