View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips[_6_] Bob Phillips[_6_] is offline
external usenet poster
 
Posts: 11,272
Default Adding a Menu Item into a sheet as a button

Try using

application.Dialogs(xlDialogInsertHyperlink).Show

This will add to the active cell.

--

HTH

RP
(remove nothere from the email address if mailing direct)


wrote in message
ups.com...
I'm a VBA beginner trying to pick up some tips quickly to simplify some
company tasks. We have employees enter information into a worksheet
and I'm trying to create a step-by-step procedure that's as dummy-proof
as possible (judging from the mistakes people are making, it's
essential). I'm fine with assigning macros to buttons inserted into a
page, but one thing I can't figure out how to do is add a very basic
menu item to a button that sits within the sheet.

For example, I need for the employees to insert a hyperlink to a
network file into a specific cell (the file name and network location
will change every time). So I want users to push a button in the
spreadsheet that says "Insert Hyperlink," let them browse to the
appropriate file and then have it inserted into the cell. This is the
same result they'd get by placing the cursor in the cell and hitting
Ctrl-K. I can't record the macro without selecting a specific file.

I"m sure this is painfully easy but I can't find anything. Can someone
out there take pity on a VBA newbie?

Thanks.