VLMenuPlus Reference

MethodGetDefaultPicture

See Also See Also Applies To Applies To

Returns the defaupicture object corresponding to specified menu caption. If there is no default picture, it returns nothing.

 

Syntax

object.GetDefaultPicture(ByVal sMenuCaption As String)

 

The GetDefaultPicture method syntax has these parts:

Part Description
object An object expression that evaluates to an object of VLMenuPlus type.
sMenuCaption A menu caption string.

 

Remarks

VLMenuPlus provides default bitmaps for a large number of commonly used menu items. You can use this function to access any of these bitmaps.

Note

sMenuCaption is assumed to have the same language as specified by the Language property. If you want to lookup a picture using a menu caption string which is in a different language, use GetDefaultPictureEx.

Typically you will use this function to get the picture object when your menu caption is slightly different from one assumed by VLMenuPlus.

Sample


   Private Sub VLMenuPlus1_SetMenuItemAttributes(ByVal mnuItem As CMenuItem)
      If (mnuItem.Caption = "Search Web...") Then
         Set mnuItem.Picture = VLMenuPlus1.GetDefaultPicture("WEB SEARCH")
      End If
   End Sub

This sample shows how to use default bitmap when menu caption is slightly different from the menu caption listed in default bitmap list.