Community
Hi,
I would be happy to know how to add a custom icon with link and image ; similar to Wiki Icon in Autodesk Inventor in the Get Started Tab and in the community panel
I would be happy to add a facebook Icon within the community panel any one can you help me in getting the right code for this
Below VBA code sample demonstrates how to add a button onto ribbon with icon, but you may want to create an addin to achieve your goal:
Sub AddPanelToGetStartedTab() ThisApplication.Documents.CloseAll False ' Get the ribbon associated with the zero-doc Dim oPartRibbon As Ribbon Set oPartRibbon = ThisApplication.UserInterfaceManager.Ribbons.Item("ZeroDoc") ' Get the "GetStarted" tab Dim oTab As RibbonTab Set oTab = oPartRibbon.RibbonTabs.Item("id_GetStarted") ' Create a panel named "Update", positioned after the "Measure" panel in the Tools tab. Dim oPanel As RibbonPanel Set oPanel = oTab.RibbonPanels.Add("Custom", "ToolsTabCustomPanel", "SampleClientId") ' Create an icon, modify the path to your icon Dim oIcon As IPictureDisp Set oIcon = stdole.LoadPicture("C:\Program Files\Autodesk\Inventor 2011\Bin\app.ico") ' Create a custom command Dim oDef1 As ButtonDefinition Set oDef1 = ThisApplication.CommandManager.ControlDefinitions.AddButtonDefinition("CustomIcon", "CustomIcon", kQueryOnlyCmdType, "Client_id", , , oIcon, oIcon) ' Create a button control Call oPanel.CommandControls.AddButton(oDef1, True) ' oDef1.Delete ' oPanel.Delete End Sub
Search in Inventor API Help for "working with the ribbon ui api" topic you may get more info on how to customize ribbon UI.