From c1937cccd0985e86e247287faa9ac60870feecd7 Mon Sep 17 00:00:00 2001 From: xue <> Date: Sun, 27 Aug 2006 23:26:55 +0000 Subject: Merge from 3.0 branch till 1350. --- framework/Web/UI/WebControls/TButtonColumn.php | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'framework/Web/UI/WebControls/TButtonColumn.php') diff --git a/framework/Web/UI/WebControls/TButtonColumn.php b/framework/Web/UI/WebControls/TButtonColumn.php index 20844f14..fdcf58d3 100644 --- a/framework/Web/UI/WebControls/TButtonColumn.php +++ b/framework/Web/UI/WebControls/TButtonColumn.php @@ -39,6 +39,14 @@ Prado::using('System.Web.UI.WebControls.TImageButton'); * The buttons' CausesValidation and ValidationGroup property values * are determined by the column's corresponding properties. * + * The buttons in the column can be accessed by one of the following two methods: + * + * $datagridItem->ButtonColumnID->Button + * $datagridItem->ButtonColumnID->Controls[0] + * + * The second method is possible because the button control created within the + * datagrid cell is the first child. + * * @author Qiang Xue * @version $Revision: $ $Date: $ * @package System.Web.UI.WebControls @@ -238,6 +246,7 @@ class TButtonColumn extends TDataGridColumn if($this->getDataTextField()!=='' || ($buttonType==='ImageButton' && $this->getDataImageUrlField()!=='')) $button->attachEventHandler('OnDataBinding',array($this,'dataBindColumn')); $cell->getControls()->add($button); + $cell->registerObject('Button',$button); } } -- cgit v1.2.3