View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
David494[_2_] David494[_2_] is offline
external usenet poster
 
Posts: 1
Default Get selected cell name/address


Hey its ok, i got it.

I just wanted to copy the info in the selected cell and place it into
an input box.

If any one was interested, then here's the code.......


'This code gets the selected cell, copies it and places it in the input
box
Dim selectedCell As Range
Set selectedCell = Selection
'MsgBox selectedCell.Address
'copy the range
selectedCell.Copy

'Place the text into the default property
Dim varInput As String
varInput = InputBox("What do you want to search for?", , selectedCell)

Thanks

Dave


--
David494
------------------------------------------------------------------------
David494's Profile: http://www.excelforum.com/member.php...o&userid=24482
View this thread: http://www.excelforum.com/showthread...hreadid=391783