info on faceid

J

JohnE

Hello. I'm using Excel 2003 and setting up several buttons. Rather then a
picture, the users would prefer text on the button face. Here is a sample of
setting the properties but I am not sure of how text is entered for the
..FaceID. If anyone knows, please let me know.

Set Btn = Tb.Controls.Add(Type:=msoControlButton)
With Btn
' .FaceId =
.OnAction = "Refresh_Metric"
.Caption = "This will refresh existing workbook."
End With

Thanks.
John
 
J

Jim Rech

If you want to see the caption instead of an icon you have to change the
button's style:

With Btn
.Style = msoButtonCaption


--
Jim
| Hello. I'm using Excel 2003 and setting up several buttons. Rather then
a
| picture, the users would prefer text on the button face. Here is a sample
of
| setting the properties but I am not sure of how text is entered for the
| .FaceID. If anyone knows, please let me know.
|
| Set Btn = Tb.Controls.Add(Type:=msoControlButton)
| With Btn
| ' .FaceId =
| .OnAction = "Refresh_Metric"
| .Caption = "This will refresh existing workbook."
| End With
|
| Thanks.
| John
 
J

JohnE

Jim, thanks for the info. Then for the FaceID do I put something like
"Refresh" (using quotes), as the .Caption was for the tool tip when hovering
over the button?
.... John
 
J

Jim Rech

When you change the style to msoButtonCaption the .Caption property is both
the caption and the tool tip. That is unless you supply a different tooltip
using the .TooltipText property. Then that value is shown as the tool tip
instead of the caption

With the msoButtonCaption style there is no need for a FaceID value since
there is no image shown.

You can show both an icon and a caption however if you use this style:
msoButtonIconAndCaption. This makes for a pretty big tool button but then a
long caption does too.
--
Jim
| Jim, thanks for the info. Then for the FaceID do I put something like
| "Refresh" (using quotes), as the .Caption was for the tool tip when
hovering
| over the button?
| ... John
|
|
| "Jim Rech" wrote:
|
| > If you want to see the caption instead of an icon you have to change the
| > button's style:
| >
| > With Btn
| > .Style = msoButtonCaption
| >
| >
| > --
| > Jim
| > | > | Hello. I'm using Excel 2003 and setting up several buttons. Rather
then
| > a
| > | picture, the users would prefer text on the button face. Here is a
sample
| > of
| > | setting the properties but I am not sure of how text is entered for
the
| > | .FaceID. If anyone knows, please let me know.
| > |
| > | Set Btn = Tb.Controls.Add(Type:=msoControlButton)
| > | With Btn
| > | ' .FaceId =
| > | .OnAction = "Refresh_Metric"
| > | .Caption = "This will refresh existing workbook."
| > | End With
| > |
| > | Thanks.
| > | John
| >
| >
| >
 

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