You are not logged in.

Dear visitor, welcome to Jabaco - Community. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

rebung

Beginner

  • "rebung" started this thread

Posts: 1

Date of registration: Dec 30th 2009

  • Send private message

1

Monday, January 4th 2010, 9:06am

Event handler

Hello Community
I would want to know how to create event handler
For example, event handler popup menu

I'm try using JPopupMenu, but i don't know where to place it's event handler...

Thanx alot.

A1880

Intermediate

  • "A1880" is male

Posts: 500

Date of registration: Jan 1st 2009

Location: Hanover, Germany

Occupation: Software Engineer

Hobbies: Hilbert Curves

  • Send private message

2

Monday, January 4th 2010, 9:49am

If your pop-up is a Dialog, you could define the following handler in the source of your Form:

Jabaco Source

1
2
3
4
5
6
7
8
9
10
11
12
Public Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
   Dim dlg As Dialog1
   
   If Button = 2 Then
      '  start pop-up on right mouse click
      dlg = New Dialog1
      
      dlg.Left = Me.Left + X
      dlg.Top = Me.Top + Y
      dlg.Show vbModal      
   End If
End Sub


You might want to digg this forum using the search facility.
There were some postings on menu handling.

Success!

A1880

Rate this thread
WoltLab Burning Board