Buttonbar 2007 button with a attached Popup menu

User avatar
Daniel Garcia-Gil
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita
Contact:

Re: Buttonbar 2007 button with a attached Popup menu

Post by Daniel Garcia-Gil »

Hello otto

can you post a "fake" image what do you want ??

thanks...
our best documentation is the source code
Isla de Margarita Venezuela.
danielgarciagil@gmail.com
http://tdolphin.blogspot.com/
https://www.dropbox.com/referrals/NTI5N ... rc=global9
User avatar
Otto
Posts: 4470
Joined: Fri Oct 07, 2005 7:07 pm
Contact:

Re: Buttonbar 2007 button with a attached Popup menu

Post by Otto »

Hello Daniel,
thank you for coming back to my question.
If I open the attached menu with the arrow down from the button the menu aligns correctly. If I press the button with the Action This:showPopup() the menu aligns wrong. Please see the bitmap.
Thanks in advance
Otto


Image

Code: Select all

DEFINE BUTTON OF oBar ;
      RESOURCE "REPORT" TOP ;
      PROMPT "Report" ;
      MENU ReportMenu( oBrw ) ;
      ACTION This:ShowPopUp() ;
      MESSAGE "Print the browse contents" ;
      TOOLTIP { "Print Report", "Report" }
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org

********************************************************************
User avatar
Daniel Garcia-Gil
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita
Contact:

Re: Buttonbar 2007 button with a attached Popup menu

Post by Daniel Garcia-Gil »

Otto...

are you using BTNBMP or RBBTN??
our best documentation is the source code
Isla de Margarita Venezuela.
danielgarciagil@gmail.com
http://tdolphin.blogspot.com/
https://www.dropbox.com/referrals/NTI5N ... rc=global9
User avatar
Otto
Posts: 4470
Joined: Fri Oct 07, 2005 7:07 pm
Contact:

Re: Buttonbar 2007 button with a attached Popup menu

Post by Otto »

Daniel, I think it is RBBTN. Here is the ppo file:

Code: Select all

oBtnBearbeiten := oFunktionen:AddButton( 5, 145, 75, 65, "Bearbeiten", {|Self|( oBtnBearbeiten:ShowPopup() )}, Upper("SPLITPOPUP"),, ".\bitmaps2\11.bmp",, .T., Upper("TOP"), oMenuBearbeiten,,,, )
Best regards,
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org

********************************************************************
User avatar
Daniel Garcia-Gil
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita
Contact:

Re: Buttonbar 2007 button with a attached Popup menu

Post by Daniel Garcia-Gil »

Otto..

you dont need call ShowPopup()

use MENU oMenu in command ADD BUTTON
sample

@ 3,5 ADD BUTTON oBtn PROMPT "Change" BITMAP "mybitmap" GROUP oGr MENU oMenu ;
SPLITPOPUP ROUND SIZE 65,75 TOP
our best documentation is the source code
Isla de Margarita Venezuela.
danielgarciagil@gmail.com
http://tdolphin.blogspot.com/
https://www.dropbox.com/referrals/NTI5N ... rc=global9
User avatar
Otto
Posts: 4470
Joined: Fri Oct 07, 2005 7:07 pm
Contact:

Re: Buttonbar 2007 button with a attached Popup menu

Post by Otto »

Daniel,
But I want to open the menu also with a click on the button not only on the arrow.
Best regards,
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org

********************************************************************
User avatar
Daniel Garcia-Gil
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita
Contact:

Re: Buttonbar 2007 button with a attached Popup menu

Post by Daniel Garcia-Gil »

Otto...


if you dont define ACTION the default action will be ShowPopup()

see

@ 3,5 ADD BUTTON oBtn PROMPT "Change" BITMAP "mybitmap" GROUP oGr MENU oMenu ;
SPLITPOPUP ROUND SIZE 65,75 TOP

i dont defined action in this button, when you push the button the popup menu is displayed
our best documentation is the source code
Isla de Margarita Venezuela.
danielgarciagil@gmail.com
http://tdolphin.blogspot.com/
https://www.dropbox.com/referrals/NTI5N ... rc=global9
User avatar
Otto
Posts: 4470
Joined: Fri Oct 07, 2005 7:07 pm
Contact:

Re: Buttonbar 2007 button with a attached Popup menu

Post by Otto »

Hello Daniel,
thank you so much. Now all is working perfectly.
I didn’t know about that.
Best regards,
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org

********************************************************************
Post Reply