We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Displaying Context Menu in GGC control

Hi,

I'm trying to programmatically display the context menu for a gridgroupingcontrol.

I have several rows selected and now I want to display the contextmenu for that grid.

I've tried:
Set objGrid= SwfWindow("x").SwfObject("y")
objGrid.Object.ContextMenu.Show(objGrid.Object, objGrid.Object.PointToClient(Control.MousePosition))

But I receive an error:
"Object required Control"

Thanks for the help!



3 Replies

NR Nirmal Raja Syncfusion Team July 30, 2008 02:26 PM UTC

Hi brxb,

The GridGroupingControl can have the popup menu control instead of the ContextMenuStrip.
The popup menu works with a method called Select given to the menu item.
For the first time the popup menu item should be right clicked once, when the Form loaded for recording.

Please refer the simple sample below that illustrates this behavior:
ContextMenuInGGCSample.zip

Let me know if you have any queries.

Regards,
Nirmal



BB Bruce Bradford July 30, 2008 04:20 PM UTC

Hmm. Ya, I've seen these before but I think it's a contextmenu given this information.

the swftypename == System.Windows.Forms.ContextMenuStrip

The selecting of the menu option works fine but I want to make the context menu show/display/popup
using code and not a function like MouseDown.

Thanks again

>Hi brxb,

The GridGroupingControl can have the popup menu control instead of the ContextMenuStrip.
The popup menu works with a method called Select given to the menu item.
For the first time the popup menu item should be right clicked once, when the Form loaded for recording.

Please refer the simple sample below that illustrates this behavior:
ContextMenuInGGCSample.zip

Let me know if you have any queries.

Regards,
Nirmal





NR Nirmal Raja Syncfusion Team July 31, 2008 01:08 PM UTC

Hi brxb,

Thank you for your continued interest in Syncfusion product.

It seems that the context menu you used in the sample is not suppose to be the Syncfusion product, it must be the product of Mercury.
As we are not able to provide support to other products, you can please contact the support of the Mercury QTP supports.
If there is any further need regarding Syncfusion product, please let me know.

Regards,
Nirmal


Loader.
Live Chat Icon For mobile
Up arrow icon