How can i check whether a toolbar menu exist or not.
If the toolbar menu doesnt exist or if the toolbar menu is disabled, i need to throw an error message.
Can someone help me on this issue, please
Regards,
tinu
Tinu,
You can get a reference to a particular tool by means of code like this:
Dim tooltool = SwfWindow("Testing Ribbon").SwfToolbar("_Form1_Toolbars_Dock_Area_Top").GetNAProperty("Ribbon.Tabs[0].Groups[0].Tools[3].Tools[1]")MsgBox(tool)
You can loop through the Tools in a Group (or another Tool) and save the Keys of the tools and then search for the Key that you are looking for.
Let me know if this helps.
Hi Michael,
Thanks for the reply. I tried that piece of code. But its throwing the following error.
Invalid Property name: Property [Tools] not found
Line (3): "tool= SwfWindow("Test_Window").SwfToolbar("_MdiHost_Toolbars_Dock_Area_To").GetNAProperty("Ribbon.Tabs[0].Groups[1].Tools[3].Tools[1]")".
The Code tool= SwfWindow("Test_Window").SwfToolbar("_MdiHost_Toolbars_Dock_Area_To").GetNAProperty("Ribbon.Tabs[0].Groups[1].Tools[3].CaptionResolved") returns the name of the particular item.
But my requirement is to check whether that particular item is enabled or not. Could you please check it for me ASAP?
Tinu