Check/Uncheck menuPOPUP item.

Check/Uncheck menuPOPUP item.

Postby Silvio.Falconi » Sun Feb 03, 2013 4:49 pm

I have a popup menu and I want checked one item

WHEN i SELECT ONE MENU THE POPUP MUST CHANGE ON THE LAST ACTION
HOW i CAN MAKE IT ?
THE SMALL TEST

Code: Select all  Expand view
#include "fivewin.ch"
#include "xBrowse.ch"
#include "constant.ch"
#include "ribbon.ch"



#define TOPSCOPE      0
#define BOTTOMSCOPE   1

REQUEST DBFCDX
REQUEST DBFFPT
EXTERNAL ORDKEYNO,ORDKEYCOUNT,ORDCREATE,ORDKEYGOTO



Function test()
Local oDlg
   Local nBottom   := 38.9
   Local nRight    := 106.5
   Local nWidth :=  Max( nRight * DLG_CHARPIX_W, 180 )
   Local nHeight := nBottom * DLG_CHARPIX_H
   Local oMenuItem[8]

 MENU oPopRecord POPUP
   MENUITEM oMenuItem[1]  PROMPT "Record and Print"
   MENUITEM oMenuItem[2]  PROMPT "Record and Email"
   MENUITEM oMenuItem[3]  PROMPT "Record and Fax"
   MENUITEM oMenuItem[4]  PROMPT "Record and Payment"
   MENUITEM oMenuItem[5]  PROMPT "Record only"
   MENUITEM oMenuItem[6]  PROMPT "Save as Draft"
   MENUITEM oMenuItem[7]  PROMPT "Save as Recurring"
   SEPARATOR
   MENUITEM oMenuItem[8]  PROMPT "Preview"
ENDMENU

oMenuItem[5]:SetCheck( .T. )




DEFINE DIALOG oDlg        ;
   TITLE "New Invoice"    ;
   SIZE nWidth, nHeight  TRANSPARENT PIXEL



@ 270, 65 RBBTN PROMPT "Record select     ";
          SIZE  100,12 ;
          OF oDlg PIXEL ;
          POPUP  MENU oPopRecord BORDER ROUND



ACTIVATE DIALOG oDlg centered


RETURN NIL






 
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)
I use : FiveWin for Harbour November 2023 - January 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
User avatar
Silvio.Falconi
 
Posts: 7056
Joined: Thu Oct 18, 2012 7:17 pm

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 120 guests