Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
JNW JNW is offline
external usenet poster
 
Posts: 480
Default How do I create a custom image for a toolbar?

Instead of
.FaceId = 98

Put...
.Picture = LoadPicture("C:\My picture location")

Note that only certain file types can be used (I don't remember off hand
which ones don't work).

JNW

" wrote:

The toolbar is being generated upon loading of the excel add-in via the
following code:

Set cmdRW = CommandBars.Add(Name:="DT")


With cmdRW

With .Controls.Add(Type:=msoControlButton)
.TooltipText = "New Sheet"
.OnAction = "Sheet"
.FaceId = 98

I know how to design a new button image when creating a toolbar
manually, but how do I do so when creating the toolbar programtically?

Thanks!


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Toolbar Button Image Question [email protected] Excel Worksheet Functions 1 August 30th 06 09:13 PM
How to increase size of image in button (msocontrolbutton) of custom toolbar of Excel padam Excel Discussion (Misc queries) 0 August 11th 06 07:18 PM
Load image from directory for custom toolbar of Excel 2000 Padam Excel Worksheet Functions 0 August 5th 06 06:33 PM
custom toolbar buttons are saved where? Excel loads twice bymistake and all my custom toolbar buttons get gone!!! Kevin Waite Excel Programming 2 March 3rd 04 03:31 PM
saving toolbar buttons on custom toolbar Paul James Excel Programming 12 August 6th 03 08:28 AM


All times are GMT +1. The time now is 11:56 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"