⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mainmenu.mpr

📁 vf编译的工资管理系统 vf编译的工资管理系统
💻 MPR
字号:
*       *********************************************************
*       *                                                         
*       * 09/19/03            MAINMENU.MPR              00:28:17  
*       *                                                         
*       *********************************************************
*       *                                                         
*       * 作者名称                                                
*       *                                                         
*       * 版权所有 (C) 2003 公司名称                             
*       * 地址                                                    
*       * 城市,     邮编                                          
*       * 国家                                              
*       *                                                         
*       * 说明:                                            
*       * 此程序由 GENMENU 自动生成。    
*       *                                                         
*       *********************************************************

* To attach this menu to your Top-Level form, 
* call it from the Init event of the form:

* Syntax: DO <mprname> WITH <oFormRef> [,<cMenuname>|<lRename>][<lUniquePopups>]

*	oFormRef - form object reference (THIS)
*	cMenuname - name for menu (this is required for Append menus - see below)
*	lRename - renames Name property of your form
*	lUniquePopups - determines whether to generate unique ids for popup names
			
* 	example:

*	PROCEDURE Init
*		DO mymenu.mpr WITH THIS,.T.
*	ENDPROC

* Use the optional 2nd parameter if you plan on running multiple instances
* of your Top-Level form. The preferred method is to create an empty string
* variable and pass it by reference so you can receive the form name after
* the MPR file is run. You can later use this reference to destroy the menu.

*	PROCEDURE Init
*		LOCAL cGetMenuName
*		cGetMenuName = ""
*		DO mymenu.mpr WITH THIS, m.cGetMenuName
*	ENDPROC

* The logical lRename parameter will change the name property of your 
* form to the same name given the menu and may cause conflicts in your 
* code if you directly reference the form by name.

* You will also need to remove the menu when the form is destroyed so that it does 
* not remain in memory unless you wish to reactivate it later in a new form.

* If you passed the optional lRename parameter as .T. as in the above example, 
* you can easily remove the menu in the form's Destroy event as shown below.
* This strategy is ideal when using multiple instances of Top-Level forms.

*	example:

*	PROCEDURE Destroy
*		RELEASE MENU (THIS.Name) EXTENDED
*	ENDPROC

* Using Append/Before/After location options:

*   You might want to append a menu to an existing Top-Level form by setting 
*   the Location option in the General Options dialog. In order to do this, you 
*   must pass the name of the menu in which to attach the new one. The second
*   parameter is required here. If you originally created the menu with the lRename 
*   parameter = .T., then you can update the menu with code similar to the following:

*	example:

*	DO mymenu2.mpr WITH THISFORM,THISFORM.name
*
* Using lUniquePopups:

*   If you are running this menu multiple times in your application, such as in multiple 
*   instances of the same top-level form, you should pass .T. to the lUniquePopups 
*   parameter so that unique popup names are generated to avoid possible conflicts.

*	example:

*	PROCEDURE Init
*		DO mymenu.mpr WITH THIS,.T.,.T.
*	ENDPROC
*
* Note: Parm4-Parm9 are not reserved and freely available for use with your menu code.
*

LPARAMETERS oFormRef, getMenuName, lUniquePopups, parm4, parm5, parm6, parm7, parm8, parm9
LOCAL cMenuName, nTotPops, a_menupops, cTypeParm2, cSaveFormName
IF TYPE("m.oFormRef") # "O" OR ;
  LOWER(m.oFormRef.BaseClass) # 'form' OR ;
  m.oFormRef.ShowWindow # 2
	MESSAGEBOX([只能从顶层表单调用该菜单。请确认您表单的 ShowWindow 属性已设为 2。阅读此菜单 MPR 文件的头部分,可以获得详细信息。])
	RETURN
ENDIF
m.cTypeParm2 = TYPE("m.getMenuName")
m.cMenuName = SYS(2015)
m.cSaveFormName = m.oFormRef.Name
IF m.cTypeParm2 = "C" OR (m.cTypeParm2 = "L" AND m.getMenuName)
	m.oFormRef.Name = m.cMenuName
ENDIF
IF m.cTypeParm2 = "C" AND !EMPTY(m.getMenuName)
	m.cMenuName = m.getMenuName
ENDIF
DIMENSION a_menupops[4]
IF TYPE("m.lUniquePopups")="L" AND m.lUniquePopups
	FOR nTotPops = 1 TO ALEN(a_menupops)
		a_menupops[m.nTotPops]= SYS(2015)
	ENDFOR
ELSE
	a_menupops[1]="数据编辑"
	a_menupops[2]="查询统计"
	a_menupops[3]="打印报表"
	a_menupops[4]="数据维护"
ENDIF


*       *********************************************************
*       *                                                         
*       *                         菜单定义                        
*       *                                                         
*       *********************************************************
*

DEFINE MENU (m.cMenuName) IN (m.oFormRef.Name) BAR

DEFINE PAD _11v010e4b OF (m.cMenuName) PROMPT "数据编辑" COLOR SCHEME 3 ;
	KEY CTRL+A, "CTRL+A"
DEFINE PAD _11v010e4c OF (m.cMenuName) PROMPT "查询统计" COLOR SCHEME 3
DEFINE PAD _11v010e4d OF (m.cMenuName) PROMPT "打印报表" COLOR SCHEME 3
DEFINE PAD _11v010e4e OF (m.cMenuName) PROMPT "数据维护" COLOR SCHEME 3
DEFINE PAD _11v010e4f OF (m.cMenuName) PROMPT "退出系统" COLOR SCHEME 3
ON PAD _11v010e4b OF (m.cMenuName) ACTIVATE POPUP (a_menupops[1])
ON PAD _11v010e4c OF (m.cMenuName) ACTIVATE POPUP (a_menupops[2])
ON PAD _11v010e4d OF (m.cMenuName) ACTIVATE POPUP (a_menupops[3])
ON PAD _11v010e4e OF (m.cMenuName) ACTIVATE POPUP (a_menupops[4])
ON SELECTION PAD _11v010e4f OF (m.cMenuName) main.release

DEFINE POPUP (a_menupops[1]) MARGIN RELATIVE SHADOW COLOR SCHEME 4
DEFINE BAR 1 OF (a_menupops[1]) PROMPT "部门编码维护"
DEFINE BAR 2 OF (a_menupops[1]) PROMPT "人员变动维护"
DEFINE BAR 3 OF (a_menupops[1]) PROMPT "编辑固定工资项"
DEFINE BAR 4 OF (a_menupops[1]) PROMPT "编辑扣款项"
DEFINE BAR 5 OF (a_menupops[1]) PROMPT "考勤表输入"
DEFINE BAR 6 OF (a_menupops[1]) PROMPT "月末处理"
ON SELECTION BAR 1 OF (a_menupops[1]) do auth with main.cuserid, "部门编码维护"
ON SELECTION BAR 2 OF (a_menupops[1]) do auth with main.cuserid, "人员基本情况"
ON SELECTION BAR 3 OF (a_menupops[1]) do auth with main.cuserid, "编辑固定工资项"
ON SELECTION BAR 4 OF (a_menupops[1]) do auth with main.cuserid,"编辑扣款项"
ON SELECTION BAR 5 OF (a_menupops[1]) do auth with main.cuserid, "考勤表输入"
ON SELECTION BAR 6 OF (a_menupops[1]) do auth with main.cuserid, "月末处理"

DEFINE POPUP (a_menupops[2]) MARGIN RELATIVE SHADOW COLOR SCHEME 4
DEFINE BAR 1 OF (a_menupops[2]) PROMPT "按部门查询工资"
DEFINE BAR 2 OF (a_menupops[2]) PROMPT "按人员查询工资"
DEFINE BAR 3 OF (a_menupops[2]) PROMPT "工资汇总"
DEFINE BAR 4 OF (a_menupops[2]) PROMPT "面值汇总"
DEFINE BAR 5 OF (a_menupops[2]) PROMPT "工资分配"
ON SELECTION BAR 1 OF (a_menupops[2]) do auth with main.cuserid, "按部门查询工资"
ON SELECTION BAR 2 OF (a_menupops[2]) do auth with main.cuserid, "按人员查询工资"
ON SELECTION BAR 3 OF (a_menupops[2]) do auth with main.cuserid, "工资汇总"
ON SELECTION BAR 4 OF (a_menupops[2]) do auth with main.cuserid, "面值汇总"
ON SELECTION BAR 5 OF (a_menupops[2]) do auth with main.cuserid, "工资分配"

DEFINE POPUP (a_menupops[3]) MARGIN RELATIVE SHADOW COLOR SCHEME 4
DEFINE BAR 1 OF (a_menupops[3]) PROMPT "打印工资表"
DEFINE BAR 2 OF (a_menupops[3]) PROMPT "打印工资汇总表"
DEFINE BAR 3 OF (a_menupops[3]) PROMPT "打印面值汇总表"
ON SELECTION BAR 1 OF (a_menupops[3]) do auth with main.cuserid, "打印工资表"
ON SELECTION BAR 2 OF (a_menupops[3]) do auth with main.cuserid, "打印工资汇总表"
ON SELECTION BAR 3 OF (a_menupops[3]) do auth with main.cuserid, "打印面值汇总表"

DEFINE POPUP (a_menupops[4]) MARGIN RELATIVE SHADOW COLOR SCHEME 4
DEFINE BAR 1 OF (a_menupops[4]) PROMPT "数据备份"
DEFINE BAR 2 OF (a_menupops[4]) PROMPT "数据恢复"
DEFINE BAR 3 OF (a_menupops[4]) PROMPT "操作员"
DEFINE BAR 4 OF (a_menupops[4]) PROMPT "更改口令"
ON SELECTION BAR 1 OF (a_menupops[4]) do auth with main.cuserid, "数据备份"
ON SELECTION BAR 2 OF (a_menupops[4]) do auth with main.cuserid, "数据恢复"
ON SELECTION BAR 3 OF (a_menupops[4]) do auth with main.cuserid, "操作员权限设置"
ON SELECTION BAR 4 OF (a_menupops[4]) do auth with main.cuserid, "更改口令"

ACTIVATE MENU (m.cMenuName) NOWAIT

IF m.cTypeParm2 = "C"
	m.getMenuName = m.cMenuName
	m.oFormRef.Name = m.cSaveFormName 
ENDIF

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -