Difference between boundfield and template field in gridview

Discussion in 'C#' started by raspms, Apr 4, 2012.

  1. #1
    Bound field:
    By using bound field we can bind the data directly by using header text and datafield with out using any controls.
    Headertext : we can specify header for the data
    Datafield : Its the field which gets the data from dataset.
    Example : if we specify a field name in datafield it searches in dataset with the same column name and binds the data.
    we can define our own asp controls in bound field column only thing we can do is only binding the data.

    Template field:
    We can define our own asp controls in template field.
    and we can bind the data from dataset to template field columns directly.
     
    raspms, Apr 4, 2012 IP