主题:有前輩可以教我閱讀一下class嗎
再次請教前輩..小的用了vfp不足半個月
不過公司已經要我閱讀一個龐大的class....
小的不才幾經辛苦才懂得操作vfp的介面
class方面還是再努力也有很多不明白的地方...
para zgoto
zdbf = (substr(thisform.Name,4))
zretval = dodefault(zgoto)
___________________________________________________________________________________
para zgoto, zdbname, zclickopen
private all like z*
thisform.dbname3 = alltrim(thisform.dbname3)
zgoto = iif(type('zgoto') = 'C', zgoto, '')
zdbname = iif(type('zdbname') = 'C', zdbname, iif(empty(thisform.dbname3), alltrim(thisform.dbname), alltrim(thisform.dbname3)))
dodefault(zgoto, zdbname)
___________________________________________________________________________________
para zgoto, zdbname
private all like z*
thisform.dbname3 = alltrim(app.dbname3)
zgoto = iif(type('zgoto') = 'C', zgoto, '')
zdbname = iif(type('zdbname') = 'C', zdbname, iif(empty(thisform.dbname3), alltrim(thisform.dbname), alltrim(thisform.dbname3)))
zolockscreen = thisform.lockscreen
thisform.lockscreen = .t.
dodefault()
___________________________________________________________________________________
private all like z*
thisform.fnkey(.t.)
this.caption = app.str2(this.caption)
___________________________________________________________________________________
這是我在當中一張form 的init 用set step on 除錯工具跑過的code
其實run 這張form時 form會自動從server 中拿回最後一筆記錄顯示
起初的code小的還是可以理解 例如拿回form的名字呀..
但是卻不明白後來的幾個iff 函數可以做到拿最後一筆記錄的效果...
還望前輩指點小的[em21][em21]
不過公司已經要我閱讀一個龐大的class....
小的不才幾經辛苦才懂得操作vfp的介面
class方面還是再努力也有很多不明白的地方...
para zgoto
zdbf = (substr(thisform.Name,4))
zretval = dodefault(zgoto)
___________________________________________________________________________________
para zgoto, zdbname, zclickopen
private all like z*
thisform.dbname3 = alltrim(thisform.dbname3)
zgoto = iif(type('zgoto') = 'C', zgoto, '')
zdbname = iif(type('zdbname') = 'C', zdbname, iif(empty(thisform.dbname3), alltrim(thisform.dbname), alltrim(thisform.dbname3)))
dodefault(zgoto, zdbname)
___________________________________________________________________________________
para zgoto, zdbname
private all like z*
thisform.dbname3 = alltrim(app.dbname3)
zgoto = iif(type('zgoto') = 'C', zgoto, '')
zdbname = iif(type('zdbname') = 'C', zdbname, iif(empty(thisform.dbname3), alltrim(thisform.dbname), alltrim(thisform.dbname3)))
zolockscreen = thisform.lockscreen
thisform.lockscreen = .t.
dodefault()
___________________________________________________________________________________
private all like z*
thisform.fnkey(.t.)
this.caption = app.str2(this.caption)
___________________________________________________________________________________
這是我在當中一張form 的init 用set step on 除錯工具跑過的code
其實run 這張form時 form會自動從server 中拿回最後一筆記錄顯示
起初的code小的還是可以理解 例如拿回form的名字呀..
但是卻不明白後來的幾個iff 函數可以做到拿最後一筆記錄的效果...
還望前輩指點小的[em21][em21]