Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default PopUpMenu in Flexgrid - Excel2002

Hello,

I'd like to know if it's possible to get a PopUpMenu with Flexgrid when
using
Excel 2002 ?

Regards,

Nader


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 694
Default PopUpMenu in Flexgrid - Excel2002

Hi,

you can use a regular popup (like when right-clicking a cell) on a userform.
3 steps:
- In initialize of the Userform: create the new popup commandbar - hidden.
Call CreateMyPopup.
- In Tereminate: delete it. Call DeleteMyPopup.
- when clicking; doubleClick; or Right-Click a control, show the popup. Call
PopupMyPopup.

''' ----------------------------------------------------------
Sub CreatePopupBar()
Dim c As CommandBar
Dim cbb As CommandBarButton

''' get/create popup bar
On Error Resume Next
Set c = Application.CommandBars("MyPopup")
If Err < 0 Then
Set c = Application.CommandBars.Add(Name:="MyPopup",
Position:=msoBarPopup, temporary:=True)
End If
On Error GoTo 0

''' add controls
Set cbb = c.Controls.Add(msoControlButton)
cbb.Caption = "submenu1"
Set cbb = c.Controls.Add(msoControlButton)
cbb.Caption = "submenu2"

End Sub

Sub DeletePopupBar()
On Error Resume Next
Application.CommandBars("MyPopup").Delete
On Error GoTo 0
End Sub

Sub PopupMyPopup()
Dim c As CommandBar
Set c = Application.CommandBars("MyPopup")
c.ShowPopup
End Sub
'''-----------------------------------------------------------
--
Regards,
Sébastien
<http://www.ondemandanalysis.com


"Nader" wrote:

Hello,

I'd like to know if it's possible to get a PopUpMenu with Flexgrid when
using
Excel 2002 ?

Regards,

Nader



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
PopMenu in Flexgrid (with Excel 200) Nader[_3_] Excel Programming 0 December 14th 07 01:18 PM
Datagrid-Flexgrid JRForm Excel Programming 2 September 27th 07 06:49 PM
popupmenu Jaxo Excel Programming 0 September 15th 06 11:34 AM
Flexgrid Control Martin Excel Programming 3 May 23rd 06 06:02 PM
popupmenu is not invoking the code MVM Excel Programming 4 January 7th 05 08:41 PM


All times are GMT +1. The time now is 03:50 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"