Print Page | Close Window

MessageBar Icon

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Command Bars
Forum Description: Topics Related to Codejock Command Bars
URL: http://forum.codejock.com/forum_posts.asp?TID=19557
Printed Date: 08 June 2025 at 7:02pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: MessageBar Icon
Posted By: McKloony
Subject: MessageBar Icon
Date Posted: 08 March 2012 at 6:46am
I have a problem adding a Icon to the Message bar. I use the following code:
 
Public Sub SMeMs(ByVal MsHed As String, ByVal MsMai As String, ByVal IcnId As Long)
On Error GoTo PoErr
'MessageBar
Dim MsBar As XtremeCommandBars.MessageBar
Dim CmBrs As XtremeCommandBars.CommandBars
Set FM = frmMain
Set CmBrs = FM.comBar01
Set MsBar = CmBrs.MessageBar
With MsBar
    .AddCloseButton "Closing"
    .Message = _
        "<StackPanel Orientation='Horizontal'>" & _
        "        <Image Source='" & IcnId & "'/>" & _
        "        <TextBlock Padding='3, 0, 0, 0' VerticalAlignment='Center'><Bold>" & MsHed & "</Bold></TextBlock>" & _
        "        <TextBlock Padding='10, 0, 0, 0' VerticalAlignment='Center'>" & MsMai & "</TextBlock></StackPanel>"
    .Visible = True
End With
Exit Sub
PoErr:
If GlDbg Then MsgBox Err.Description, 48, "SMeMs " & Err.Number
Resume Next
End Sub

IcnId is dthe ID of an ImageManager Icon!

 




-------------
Product: Xtreme SuitePro (ActiveX) 16.2.5

Platform: XP / Windows 7

Language: Visual Basic 6.0 SP6



Replies:
Posted By: McKloony
Date Posted: 10 March 2012 at 2:05am
Is it possible to set a ImageManager Icon to the MessageBar ?

-------------
Product: Xtreme SuitePro (ActiveX) 16.2.5

Platform: XP / Windows 7

Language: Visual Basic 6.0 SP6



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net