1.将pfc pfe文件加入到pb 库搜索路径中
2.设置系统全局变量:sqlca 为n_tr error 为n_err message 为n_msg
3.建立全局对象gnv_app ,应用对象 event:open n_cst_appmanager gnv_app=create n_cst_appmanager
gnv_app.event pfc_open()
event:systemerror
gnv_app.event pfc_systemerror()
event :close()
if isvalid(gnv_app) then
gnv_app.event pfc_close()
destroy gnv_app
end if
4.修改 n_cst_appmanager
:connstruction 初始化版权 用户使用的注册表和配置文件 帮助文件位置等.
:open(打开服务) of_splash(1)
重要语句:sqlca.of_init('inifile','section')<>-1
sqlca.of_connect()<>-1
open(w_framemain)
处理登陆: pfc_logon
select 查询数据库
return 1 or -1
5.使用继承的方法建立主窗口(单文档继承w_master,多文档继承w_frame) ,通过传递打开ue_login
ue_login: if gnv_app.of_logon()=1 then
messagebox('提示','登陆成功')
else
messagebox('提示','登陆失败')
close(this)
end if
修改 w_login 窗口
:open
this.of_setbase(true)
this.inv_base.of_center()
建立菜单处理的事件 ue_pfcmenu() 随便建立
w_sheet lw_sheet
string ls_sheetname
ls_sheetname=message.stringparm
opensheet(lw_sheet,ls_sheetname,0,layered!)
2.设置系统全局变量:sqlca 为n_tr error 为n_err message 为n_msg
3.建立全局对象gnv_app ,应用对象 event:open n_cst_appmanager gnv_app=create n_cst_appmanager
gnv_app.event pfc_open()
event:systemerror
gnv_app.event pfc_systemerror()
event :close()
if isvalid(gnv_app) then
gnv_app.event pfc_close()
destroy gnv_app
end if
4.修改 n_cst_appmanager
:connstruction 初始化版权 用户使用的注册表和配置文件 帮助文件位置等.
:open(打开服务) of_splash(1)
重要语句:sqlca.of_init('inifile','section')<>-1
sqlca.of_connect()<>-1
open(w_framemain)
处理登陆: pfc_logon
select 查询数据库
return 1 or -1
5.使用继承的方法建立主窗口(单文档继承w_master,多文档继承w_frame) ,通过传递打开ue_login
ue_login: if gnv_app.of_logon()=1 then
messagebox('提示','登陆成功')
else
messagebox('提示','登陆失败')
close(this)
end if
修改 w_login 窗口
:open
this.of_setbase(true)
this.inv_base.of_center()
建立菜单处理的事件 ue_pfcmenu() 随便建立
w_sheet lw_sheet
string ls_sheetname
ls_sheetname=message.stringparm
opensheet(lw_sheet,ls_sheetname,0,layered!)