如何判斷 DBNavigator 所按下的按鈕 |
答題得分者是:delphiwww
|
may
一般會員 發表:32 回覆:26 積分:11 註冊:2003-02-11 發送簡訊給我 |
#1
發表時間:2003-05-08 14:34:51
IP:210.202.xxx.xxx 未訂閱
請問各位高手:
1.如何判斷 DBNavigator 所按下的按鈕是新增或刪除呢?
2.搭配 DBNavigator 時,如何得知我的 DataSet 的狀態是新增或刪除呢?
謝謝!!
|
delphiwww
資深會員 發表:145 回覆:363 積分:368 註冊:2002-03-13 發送簡訊給我 |
#2
發表時間:2003-05-08 15:37:25
IP:202.145.xxx.xxx
未訂閱
1.在OnClick 事件上有Button: TNavigateBtn的物件傳入
判斷Button=nbinsert...
Button Value Action First nbFirst Go to the first record
Prior nbPrior Go to the previous record
Next nbNext Go to the next record
Last nbLast Go to the last record
Insert nbInsert Insert a blank record
Delete nbDelete Delete the current record
Edit nbEdit Permit users to edit the current record
Post nbPost Post the current record
Cancel nbCancel Cancel the current edit
Refresh nbRefresh Refresh the data in the dataset 2.判斷你dataset的狀態應該是用state,不過好像沒有刪除的狀態
你可以用dataset.state in [dsedit,dsinsert],判斷是否在新增或修改
引言: 請問各位高手: 1.如何判斷 DBNavigator 所按下的按鈕是新增或刪除呢? 2.搭配 DBNavigator 時,如何得知我的 DataSet 的狀態是新增或刪除呢? 謝謝!! |
本站聲明 |
1. 本論壇為無營利行為之開放平台,所有文章都是由網友自行張貼,如牽涉到法律糾紛一切與本站無關。 2. 假如網友發表之內容涉及侵權,而損及您的利益,請立即通知版主刪除。 3. 請勿批評中華民國元首及政府或批評各政黨,是藍是綠本站無權干涉,但這裡不是政治性論壇! |