Thursday, November 12, 2009

ItemDataBound, ItemCommand

Here are some differences between the ItemDataBound and the ItemCommand.



ItemBound is fired when each and every record is binded with the datagrid.
ItemCommand will be fired when the control in datagrid is operated.



The ItemCreated event fires once for every DataWebControlNameItem added to the data Web control. It fires before the DataWebControlNameItem's DataItem property is assigned. The ItemDataBound event also fires once for every DataWebControlNameItem added to the data Web control, but this event fires after the DataWebControlNameItem's DataItem property is assigned. Finally, the ItemCommand event fires whenever the Command event for a Button or LinkButton within the data Web control fires


No comments: