首页
社区
课程
招聘
PB商业软件电脑台数限制
发表于: 2011-3-14 23:25 5303

PB商业软件电脑台数限制

2011-3-14 23:25
5303
这个软件限制了只能用10台电脑,不知道它是在数据库里限制,还是在程序里限制的,请高手帮忙分析一下,怎样破解它的限制.

forward
global type w_logo from window
end type
type st_7 from statictext within w_logo
end type
type dw_2 from datawindow within w_logo
end type
type st_6 from statictext within w_logo
end type
type st_1 from uo_statictext within w_logo
end type
type st_5 from uo_statictext within w_logo
end type
type st_3 from uo_statictext within w_logo
end type
type p_1 from picture within w_logo
end type
type dw_1 from datawindow within w_logo
end type
type cb_4 from uo_xpbutton within w_logo
end type
type cb_3 from uo_xpbutton within w_logo
end type
type st_4 from statictext within w_logo
end type
type cb_2 from commandbutton within w_logo
end type
type cb_1 from commandbutton within w_logo
end type
type gb_1 from groupbox within w_logo
end type
type st_2 from statictext within w_logo
end type
type sle_2 from singlelineedit within w_logo
end type
type gb_2 from groupbox within w_logo
end type

end forward

global type w_logo from window
integer width=1833
integer height=1156
boolean titlebar=TRUE
string title="系统登陆"
windowtype windowtype=response!
long backcolor=12632256
string icon="AppIcon!"
boolean center=TRUE
st_7 st_7
dw_2 dw_2
st_6 st_6
st_1 st_1
st_5 st_5
st_3 st_3
p_1 p_1
dw_1 dw_1
cb_4 cb_4
cb_3 cb_3
st_4 st_4
cb_2 cb_2
cb_1 cb_1
gb_1 gb_1
st_2 st_2
sle_2 sle_2
gb_2 gb_2
event pfc_preopen ()

end type
global w_logo w_logo

type variables
datastore ids_users
datastore ids_users1

end variables

forward prototypes
Public function long  wf_get_computer (string as_dmbh)
end prototypes
Public function long  wf_get_computer (string as_dmbh);//Public function wf_get_computer (string as_dmbh) returns long
//string as_dmbh
ulong i_size=255
string s_name
string disksn
string ls_computercnt
integer li_computercnt
integer li_out
DECLARE sp_proc PROCEDURE FOR up_get_computercnt :as_dmbh USING sqlca;
DECLARE sp_proc1 PROCEDURE FOR up_generate_workuser :as_dmbh , :s_name , :disksn , :li_computercnt , @as_out =:li_out output USING sqlca;

s_name = space(i_size)
getcomputername(s_name,i_size)
disksn = space(100)
getdisksn(0,disksn)
EXECUTE sp_proc;
FETCH sp_proc INTO :ls_computercnt;
CLOSE sp_proc;
ls_computercnt = mid(f_um_unencrypt(ls_computercnt),5,2)
li_computercnt = long(ls_computercnt)
EXECUTE sp_proc1;
FETCH sp_proc1 INTO :li_out;
CLOSE sp_proc1;
RETURN li_out

end function
event pfc_preopen;//pfc_preopen (none) returns (none)
datawindowchild ldwc_users
string ls_code

dw_2.settransobject(sqlca)
dw_1.settransobject(sqlca)
THIS.ids_users = CREATE datastore
THIS.ids_users.dataobject = "d_list_users1"
ids_users.settransobject(sqlca)
ids_users.retrieve()
IF dw_2.getchild("user_name",ldwc_users) = 1 THEN //6
        ids_users.sharedata(ldwc_users)
END IF //6
dw_2.insertrow(0)

end event

on w_logo.create
//create (none) returns (none)

THIS.st_7 = CREATE st_7
THIS.dw_2 = CREATE dw_2
THIS.st_6 = CREATE st_6
THIS.st_1 = CREATE st_1
THIS.st_5 = CREATE st_5
THIS.st_3 = CREATE st_3
THIS.p_1 = CREATE p_1
THIS.dw_1 = CREATE dw_1
THIS.cb_4 = CREATE cb_4
THIS.cb_3 = CREATE cb_3
THIS.st_4 = CREATE st_4
THIS.cb_2 = CREATE cb_2
THIS.cb_1 = CREATE cb_1
THIS.gb_1 = CREATE gb_1
THIS.st_2 = CREATE st_2
THIS.sle_2 = CREATE sle_2
THIS.gb_2 = CREATE gb_2
THIS.control = {THIS.st_7,THIS.dw_2,THIS.st_6,THIS.st_1,THIS.st_5,THIS.st_3,THIS.p_1,THIS.dw_1,THIS.cb_4,THIS.cb_3,THIS.st_4,THIS.cb_2,THIS.cb_1,THIS.gb_1,THIS.st_2,THIS.sle_2,THIS.gb_2}

end on

on w_logo.destroy
//destroy (none) returns (none)

DESTROY THIS.st_7
DESTROY THIS.dw_2
DESTROY THIS.st_6
DESTROY THIS.st_1
DESTROY THIS.st_5
DESTROY THIS.st_3
DESTROY THIS.p_1
DESTROY THIS.dw_1
DESTROY THIS.cb_4
DESTROY THIS.cb_3
DESTROY THIS.st_4
DESTROY THIS.cb_2
DESTROY THIS.cb_1
DESTROY THIS.gb_1
DESTROY THIS.st_2
DESTROY THIS.sle_2
DESTROY THIS.gb_2

end on

event open;//open (none) returns long [pbm_open]
//SHU_ERROR: Only for highlight,Maybe SomeThing Error
long ll_len
long ll_mid
long ll_pos
string ls_str1

EVENT pfc_preopen()
dw_2.settransobject(sqlca)
dw_1.settransobject(sqlca)
THIS.st_5.text = gnv_app.of_getversion()
ll_len = len(gnv_app.iapp_object.SHU_ERROR_PRO_2_3_91_10)
IF ll_len > 0 THEN //5
        ll_pos = pos(gnv_app.iapp_object.SHU_ERROR_PRO_2_3_91_10,"电脑")
        IF ll_pos > 1 THEN //7
                ls_str1 = mid(gnv_app.iapp_object.SHU_ERROR_PRO_2_3_91_10,1,ll_pos - 1)
        END IF //7
END IF //5
THIS.st_3.text = ls_str1
dw_2.insertrow(0)
dw_1.insertrow(0)
RETURN

end event

type st_7 from statictext within w_logo
integer x=293
integer y=496
integer width=398
integer height=92
boolean bringtotop=TRUE
integer textsize=-11
integer weight=700
fontcharset fontcharset=gb2312charset!
fontpitch fontpitch=fixed!
fontfamily fontfamily=modern!
string facename="幼圆"
long textcolor=33554432
long backcolor=12632256
string text="用户名:"
alignment alignment=right!
long bordercolor=30001609
boolean focusrectangle=FALSE

end type
type dw_2 from datawindow within w_logo
integer x=690
integer y=324
integer width=686
integer height=108
integer taborder=10
string title="none"
string dataobject="d_chooseuser"
boolean border=FALSE
boolean livescroll=TRUE

end type
event itemchanged;//itemchanged (long row,dwobject dwo,string data) returns long [pbm_dwnitemchange]
//long row
//dwobject dwo
//string data
datawindowchild ldwc_users1
string ls_code

PARENT.dw_1.settransobject(sqlca)
accepttext()
ls_code = getitemstring(getrow(),"user_name")
PARENT.ids_users1 = CREATE datastore
PARENT.ids_users1.dataobject = "d_list_users11"
PARENT.ids_users1.settransobject(sqlca)
PARENT.ids_users1.retrieve(ls_code)
IF PARENT.dw_1.getchild("user_name",ldwc_users1) = 1 THEN //7
        PARENT.ids_users1.sharedata(ldwc_users1)
END IF //7
PARENT.dw_1.setfocus()
RETURN

end event

type st_6 from statictext within w_logo
integer x=283
integer y=348
integer width=407
integer height=96
boolean bringtotop=TRUE
integer textsize=-11
integer weight=700
fontcharset fontcharset=gb2312charset!
fontpitch fontpitch=fixed!
fontfamily fontfamily=modern!
string facename="幼圆"
long textcolor=33554432
long backcolor=12632256
string text="机构名称:"
alignment alignment=right!
long bordercolor=30001609
boolean focusrectangle=FALSE

end type
type st_1 from uo_statictext within w_logo
integer x=699
integer y=128
integer width=613
integer textsize=-14
string facename="华文新魏"
long textcolor
string text="电脑管理系统"
alignment alignment=center!

end type
type st_5 from uo_statictext within w_logo
integer x=1307
integer y=160
integer width=297
integer textsize=-10
string facename="华文新魏"
long textcolor
string text="1.0"

end type
type st_3 from uo_statictext within w_logo
integer x=297
integer y=28
integer width=1527
integer height=96
integer textsize=-14
string facename="华文新魏"
long textcolor
string text="技术开发有限公司"
alignment alignment=center!

end type
type p_1 from picture within w_logo
integer width=1829
integer height=236
string picturename="PIC\HEAD.bmp"
boolean focusrectangle=FALSE

end type
type dw_1 from datawindow within w_logo
integer x=690
integer y=472
integer width=686
integer height=124
integer taborder=20
string title="none"
string dataobject="d_chooseuser"
boolean border=FALSE
boolean livescroll=TRUE
event ue_key pbm_dwnkey

end type
event ue_key;//ue_key (keycode key,ulong keyflags) returns long [pbm_dwnkey]
//keycode key
//ulong keyflags

IF key = keyenter! THEN //0
        CHOOSE CASE key //1
                CASE keyenter! //1
                        send(handle(THIS),256,9,long(0,0))
        END CHOOSE //1
        RETURN 1
END IF //0
RETURN

end event

event itemchanged;//itemchanged (long row,dwobject dwo,string data) returns long [pbm_dwnitemchange]
//long row
//dwobject dwo
//string data

PARENT.sle_2.setfocus()
RETURN

end event

type cb_4 from uo_xpbutton within w_logo
integer x=1074
integer y=892
integer taborder=50
integer textsize=-10
fontpitch fontpitch=fixed!
fontfamily fontfamily=modern!
string facename="幼圆"
string text="取消[&C]"
integer buttonstyle=1

end type
event clicked;call super::clicked;//clicked (none) returns long [pbm_bnclicked]
//long ancestorreturnvalue

PARENT.cb_2.triggerevent(clicked!)
RETURN

end event

type cb_3 from uo_xpbutton within w_logo
integer x=709
integer y=892
integer taborder=60
integer textsize=-10
fontpitch fontpitch=fixed!
fontfamily fontfamily=modern!
string facename="幼圆"
string text="确定[&D]"
integer buttonstyle=1

end type
event clicked;call super::clicked;//clicked (none) returns long [pbm_bnclicked]
//long ancestorreturnvalue

PARENT.cb_1.triggerevent(clicked!)
RETURN

end event

type st_4 from statictext within w_logo
boolean visible
integer x=69
integer y=116
integer width=169
integer height=60
integer textsize=-9
integer weight=400
fontcharset fontcharset=gb2312charset!
fontpitch fontpitch=variable!
string facename="宋体"
long textcolor=33554432
long backcolor=16777215
string text="版本:"
boolean focusrectangle=FALSE

end type
type cb_2 from commandbutton within w_logo
boolean visible=FALSE
integer x=1029
integer y=632
integer width=293
integer height=92
integer textsize=-9
integer weight=400
fontcharset fontcharset=gb2312charset!
fontpitch fontpitch=variable!
string facename="宋体"
string text="取  消"

end type
event clicked;//clicked (none) returns long [pbm_bnclicked]

close(PARENT)
RETURN

end event

type cb_1 from commandbutton within w_logo
boolean visible=FALSE
integer x=640
integer y=632
integer width=293
integer height=92
integer textsize=-9
integer weight=400
fontcharset fontcharset=gb2312charset!
fontpitch fontpitch=variable!
string facename="宋体"
string text="确  定"

end type
event clicked;//clicked (none) returns long [pbm_bnclicked]
string ls_usercode
string ls_name
string ls_jpcw
string ls_bm
string ls_gsck
string ls_pjcwcode
string ls_pjcwgrant
string ls_loginid
string ls_jgcode
string ls_refresh
datawindowchild ldw_child
integer li_ret
integer li_zlwxf
integer li_zlpjf
long ll_rowcount
long ll_row
integer li_out
string ls_gsqc
string ls_passwrd
string ls_grant
string ls_dmbh
string ls_bmmc
string gsbs
string bbbt
string ls_gsdz
string ls_gsdh
string ls_gszh
string ls_gskhh
string ls_displayname
string ls_gsbs
//str_system str_sys

PARENT.dw_1.accepttext()
ls_usercode = trim(PARENT.dw_1.getitemstring(1,1))
IF (isnull(ls_usercode) OR ls_usercode = "") THEN //2
        messagebox("提示","请输入用户编号!")
        RETURN
END IF //2
ls_jgcode = trim(PARENT.dw_2.getitemstring(1,"user_name"))
IF (isnull(ls_jgcode) OR ls_jgcode = "") THEN //6
        messagebox("提示","请输入机构名称!")
        RETURN
END IF //6
ll_row = PARENT.ids_users1.find("dmbh = '" + ls_usercode + "'",1,PARENT.ids_users1.rowcount())
IF ll_row <= 0 THEN //10
        messagebox("提示","不存在的用户!")
        RETURN
END IF //10
ls_loginid = PARENT.ids_users1.object.dmbh[ll_row]
li_out = PARENT.wf_get_computer(left(ls_loginid,3))
IF li_out = -100 THEN //15               (如果在这里设成不等,能进入系统,就是进入系统后没有用户名了,有些功能不能用.)
        messagebox("信息","分店电脑数量超限,请与软件供应商联系!")
        RETURN
END IF //15
//SHU_ERROR:DEMO_SCRIPT_LIMIT.
end event

type gb_1 from groupbox within w_logo
boolean visible=FALSE
integer y=652
integer width=1618
integer height=8
integer textsize=-9
integer weight=400
fontcharset fontcharset=ansi!
fontpitch fontpitch=variable!
fontfamily fontfamily=swiss!
string facename="Arial"
long textcolor=33554432
long backcolor=67108864

end type
type st_2 from statictext within w_logo
integer x=325
integer y=640
integer width=366
integer height=92
boolean bringtotop=TRUE
integer textsize=-11
integer weight=700
fontcharset fontcharset=gb2312charset!
fontpitch fontpitch=fixed!
fontfamily fontfamily=modern!
string facename="幼圆"
long textcolor=33554432
long backcolor=12632256
string text="密 码:"
alignment alignment=right!
long bordercolor=30001609
boolean focusrectangle=FALSE

end type
type sle_2 from singlelineedit within w_logo
integer x=695
integer y=620
integer width=663
integer height=92
integer taborder=30
boolean bringtotop=TRUE
integer textsize=-9
integer weight=400
fontcharset fontcharset=ansi!
fontpitch fontpitch=variable!
fontfamily fontfamily=swiss!
string facename="Arial"
long textcolor=33554432
boolean password=TRUE
borderstyle borderstyle=stylelowered!
event key pbm_keydown

end type
event key;//key (keycode key,ulong keyflags) returns long [pbm_keydown]
//keycode key
//ulong keyflags

IF key = keyenter! THEN //0
        PARENT.cb_1.EVENT clicked()
END IF //0
RETURN

end event

event getfocus;//getfocus (none) returns long [pbm_ensetfocus]

selecttext(1,len(THIS.text))
RETURN

end event

type gb_2 from groupbox within w_logo
integer x=14
integer y=220
integer width=1787
integer height=564
integer taborder=40
integer textsize=-10
integer weight=700
fontcharset fontcharset=gb2312charset!
fontpitch fontpitch=variable!
string facename="宋体"
long textcolor=33554432
long backcolor=12632256

end type

[招生]科锐逆向工程师培训(2024年11月15日实地,远程教学同时开班, 第51期)

收藏
免费 0
支持
分享
最新回复 (10)
雪    币: 92
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
2
这是源码吗?
2011-3-15 03:37
0
雪    币: 194
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
3
这是我用PBKiller导出来的。
2011-3-15 12:27
0
雪    币: 90
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
4
不懂PB,帮你顶一下
2011-3-15 13:35
0
雪    币: 194
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
5
自已顶一下.
2011-3-15 21:52
0
雪    币: 194
活跃值: (30)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
6
在数据库中。
2011-3-15 21:58
0
雪    币: 194
活跃值: (30)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
7
看看这个函数up_get_computercnt
2011-3-15 21:59
0
雪    币: 194
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
8
是在数据库中看up_get_computercnt 这个函数吗?谢谢wsmwlh
2011-3-15 22:09
0
雪    币: 238
活跃值: (25)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
9
在程序中查找,看看具体调用的那个表的数据
2011-3-16 11:01
0
雪    币: 194
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
10
我在程序里找了很久也没找到up_get_computercnt 这个函数,到是在数据库的“存储过程”中倒是有这个up_get_computercnt 打开它的属性,只有下面。
CREATE procedure up_get_computercnt @as_dmbh char(6)
as
select computercnt from qx_xtgl_user1 where rtrim(dmbh) = @as_dmbh
return
GO

根据上面提示找到qx_xtgl_user1表如下图,不知怎么改。
上传的附件:
2011-3-17 20:18
0
雪    币: 29
活跃值: (12)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
11
在表上右击 打开表 返回所有行,不是双击(你用的是双击)
2011-3-31 16:13
0
游客
登录 | 注册 方可回帖
返回
//