View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
BCLivell BCLivell is offline
external usenet poster
 
Posts: 12
Default Code for activating shift key

I need help with finding code that will virtually hold down the shift key. I
code that will select one cell and then i have it finding a second cell but I
it to "hold the shift key" inbetween so it copies all of the cels inbetween.
See below for the code i have so far. thank you!

Private Sub CommandButton1_Click()
Dim rng As Range
Dim cell As Range

Set rng = Range("B1:B1000")

startrow = Columns(2).Find("example 1").Select
ActiveCell.Copy

****Hold shift key****

startrow = Columns(2).Find("example 2").Select
ActiveCell.Copy

***End holding shift key****


End Sub