[OPEN/BUG] MDI Menus with Ribbon Bar
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=17412
Printed Date: 09 June 2025 at 10:40pm Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com
Topic: [OPEN/BUG] MDI Menus with Ribbon Bar
Posted By: Hemesh
Subject: [OPEN/BUG] MDI Menus with Ribbon Bar
Date Posted: 12 October 2010 at 1:06pm
Hi,
After succesfully implementing the normal MDI Menu structure, i'm now looking to make use of the Ribbon Bar.
As soon as I set this up though, The menu's don't switch to the correct MDI Menu even though the correct IDs are getting set through code like before. Is this an issue with the RibbonBar???
------------- Product: Xtreme SuitePro (ActiveX) version 18.5.0
Platform: Windows 7 Enterprise (64-bit)
Language: Visual Basic 6.0
|
Replies:
Posted By: Xander75
Date Posted: 18 October 2010 at 7:41am
Hi Hemesh,
I am not sure if this will help or not but I had a problem getting the MDI Ribbon to work correctly a long while back. To resolve this I did the following:
Dim MDIMenu As MenuBarMDIMenu ' The number "100" must be set in the Child form "HelpContextID" for the MDI Menu to work Set MDIMenu = CommandBars.ActiveMenuBar.MDIMenus.Add(100, "Document", "Document")
|
Above is the code I use for working with the MDI Ribbon, basically you need to set the child forms to have the same ID in the the forms "HelpContextID" as that of the ID you specify in the line of code above i.e. "100".
------------- Product: Xtreme SuitePro (ActiveX) v15.3.1 Platform: Windows 7 64-bit (SP1) Professional Edition Languages: C#.Net using Visual Studio 2012 & Visual Basic 6.0 (SP6)
|
Posted By: Hemesh
Date Posted: 19 October 2010 at 3:09am
Thanks Xander, I'll try that and see what happens later tonight. They do that in the sample application whereby they set the DocID in the GetDocumentID() event to get this to work, but if you've successfully done this via the HelpContextID, it might be a CJ Bug that it's not getting set correctly.
------------- Product: Xtreme SuitePro (ActiveX) version 18.5.0
Platform: Windows 7 Enterprise (64-bit)
Language: Visual Basic 6.0
|
Posted By: Xander75
Date Posted: 19 October 2010 at 3:22am
Hemesh,
Let me know if this works for you? This is how I have got the MDI Ribbon to work since I worked with Xtreme SuitePro (ActiveX) v10.4.0 so hopefully this will fix the issue for you.
My bad, this was specifically for a MDI application that does not use the Ribbon Bar. It appears that the Ribbon Bar sample works differently and that it creates the illusion of having MDI menus by hiding/showing the menus based on the ActiveForm count.
------------- Product: Xtreme SuitePro (ActiveX) v15.3.1 Platform: Windows 7 64-bit (SP1) Professional Edition Languages: C#.Net using Visual Studio 2012 & Visual Basic 6.0 (SP6)
|
Posted By: Hemesh
Date Posted: 19 October 2010 at 3:00pm
Just tried this on my app, and on the sample CJ application and it doesn't work unfortunatly :( Is it possible that you can provide a sample bit of code in ase i'm doing something wrong?
------------- Product: Xtreme SuitePro (ActiveX) version 18.5.0
Platform: Windows 7 Enterprise (64-bit)
Language: Visual Basic 6.0
|
Posted By: Hemesh
Date Posted: 20 October 2010 at 9:55am
I have uploaded a sample application along with a word document explaining the problem
uploads/6296/MDISample.rar - uploads/6296/MDISample.rar
Oleg and the ppl at CJ, is this a bug, or something that can be easily implemented?
------------- Product: Xtreme SuitePro (ActiveX) version 18.5.0
Platform: Windows 7 Enterprise (64-bit)
Language: Visual Basic 6.0
|
|