How to create a customized icon for specific filename within toolb

E

Eric

Does anyone have any suggestions on how to create a customized icon for
specific filename within toolbar?
Within excel, there are many toolbar under the pull down menu, I would like
to add an icon within toolbar, which refer to specific filename, so whenever
user opens excel, he can click on this icon to open specific file without
going through browing the file under different directory.
Does anyone have any suggestions on how to do it in excel?
Thanks in advance for any suggestions
Eric
 
G

Gord Dibben

Turn on the macro recorder to get the code for opening a specific
workbook/file.

Customize your Toolbar by placing a button on it and assign the macro to
that button.

Tools>Customize>Commands>Macros.

Drag smiley face to your Toolbar. Right-click on smiley and "assign macro"

You can also change smiley to different Icon by right-click and "change
button image"


Gord Dibben MS Excel MVP
 
E

Eric

Thank you very much for suggestions
Could you please tell me how to create the macro to open specific file?
Thank you very much for any suggestions
Eric
 
G

Gord Dibben

Depends upon which version of Excel you are using.

In 2003 or earlier go to Tools>Macro>Record new macro.

File>Open and open the file you want.

Stop recording.

Example code from the recording looks like this..............

Sub Macro6()
' Macro6 Macro
' Macro recorded 8/4/2009 by Gord Dibben
Workbooks.Open Filename:= _
"C:\Program Files\Microsoft Office\Exceldata\12months.xls"
End Sub


Gord
 
E

Eric

Thank you very much for your suggestions
Could you please tell me how to assign the following code into the button
without opening any spreadsheet?
Do you have any suggestions?

Sub Macro1()
Workbooks.Open Filename:="E:\folder\filename.xls", UpdateLinks:=3
End Sub

Thank you very much for any suggestions
Eric
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top