Print Page | Close Window

implementing right click event

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Property Grid
Forum Description: Topics Related to Codejock Property Grid
URL: http://forum.codejock.com/forum_posts.asp?TID=10950
Printed Date: 07 July 2024 at 8:02pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: implementing right click event
Posted By: BoboP
Subject: implementing right click event
Date Posted: 07 June 2008 at 4:16am
Hi !

I need to give options to user for deletion or modification when he right clicks an item of propertygrid.

Now on right click I am getting item name and its value..I can remove it as well. But I wanted user to know about this by giving option same way we get whenever we right click anywhere . presenting context menus to user.

can anyone help in this ,. its is pretty urgent
Thanks
Bobo



Replies:
Posted By: Aaron
Date Posted: 07 June 2008 at 6:07am
Hi,
 
Do you mean a popupmenu for a PropertyGridItem? Like this:
 
 


-------------
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....


Posted By: BoboP
Date Posted: 07 June 2008 at 8:08am
Yes ! Exactly !
But I am using code jock 11.2.2 ocx property grid in c#
Is it possible . and if yes could  you suggest  some way for doing it

Thanks ,





Posted By: Aaron
Date Posted: 07 June 2008 at 8:50am
Hi,
 
Here's a VB6.0 sample:
 
Private Sub wndPropertyGridFiles_RClick(ByVal Item As XtremePropertyGrid.IPropertyGridItem)
            
Dim Popup As CommandBar
Dim ControlsView As CommandBarPopup
               
            Set Popup = CommandBars.Add("Popup", xtpBarPopup)
                With Popup.Controls
                   
                    .Add xtpControlButton, ID_1, Item.Caption, -1, True
                    .Add xtpControlButton, ID_2, Item.Value, -1, True
                   
                    Set ControlsView = .Add(xtpControlButtonPopup, ID_3, "View")
                        ControlsView.BeginGroup = True
                        ControlsView.CommandBar.Controls.Add xtpControlButton, ID_4, "Remove"
                        ControlsView.CommandBar.Controls.Add xtpControlButton, ID_5, "Edit"
                        ControlsView.CommandBar.Controls.Add xtpControlButton, ID_6, "...."
                           
                End With
        Popup.ShowPopup
End Sub
 
 
This is the PopupMenu in code like in the image, but with VB6.0
 
 
 


-------------
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2
Language: Visual Basic 6.0

Zero replies is not an option....



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