View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Steve Yandl[_3_] Steve Yandl[_3_] is offline
external usenet poster
 
Posts: 117
Default Clipboard Data Within Macro

Take a look at Chip Pearson's article
http://www.cpearson.com/excel/clipboar.htm

Steve

"Phil" wrote in message
...
Is there a way to use data a user saved in the clipboard
prior to running my macro. Or, is there a way to prompt
the user to select a range of data to copy to the
clipboard.

I attempted to use the InputBox Method with a Type:=8
setting but I get an error when I attempt to set the
return value to a variable which I declared as being of
type Range, and then try to select that range. The
specific error I get is "Run-Time error '1004'
Method 'Range' of object '_Global' failed.

------------------------
Dim Data_Copy_Range As Range

Set Data_Copy_Range = Application.InputBox(prompt:="Enter
copy range.", Type:=8)

Range(Data_Copy_Range).Select
------------------------

Please Help?
Phil