2016年9月2日 星期五

codecharge buttom on_click event

Button Control Reference

Server side event:

on_click

Occurs after the button has been clicked and the form is submitted. 
If the button appears in a record or editable grid form, record operations such as insert, update and delete occur after this event has been processed. 
In cases where the form does not have a Data Source, this event is used to perform post-submission operations such as sending emails messages based on the submitted information.

按鈕按了! ==> Form送出去了 ==> 執行本on click Event的程式 ==> 執行Insert/Update/Delete

 

沒有留言:

張貼留言

如何判斷現在FORM是在 insert mode? 還是 update mode?

只要用  if (empty({primary_key})) 就可以知道是否為新增模式了。 如果 {promary_key} 是空白的,那麼就是在新增模式;反之,就是更新模式。 以上。