L ) Gridview Paging (Sqldataadapter)

                                 * Gridview Paging  *


 * POINTS

  •     In gridview display 10 record in each page . //ekpage pe only 10 record
  •     Dataadapter is use to read data in a form of group.
  •     Dataset work with DataSet OBJECT.
  •     Cm Object can't use Adapter Concept .
  •     Adapter Object field using Dataset Object. 

      ex sqlDataAdapter (sda object name)= new sqlDataAdapter ( );

  •   Datareader read only single data .

* DATASET --write click on dataset --resolve--sqlldataadpate--ok activate ho jayega

  STEP 1  Design :- create page(gridpaging)-- gridview controle--boundfield(id,name,cusno) 

  Step 2 SOURCE ATRIBUTE :--add atribute in Grid 1)ALLOWPAGING="true" 2) OnPageIndexChanging="pagevent" 


                       


 Q)  How to pass parameter in SqldataAdapter ?

   Syntax :- SqldataAdpter objcet .SelectCommand.Parameters.Add("variable", Controlename);

 Passing paramter :-    sdp.SelectCommand.Parameters.Add("branch1", ddlbranch.Text); 

Comments

Popular posts from this blog

DATA CONTROL ( Gridview , Repeater , Formview , DataList , Detailsview , Listview )

Z 5 ) MVC (Model view Controller)

Z 8 ) MVC HTMLHELPER METHOD AND ACTIONLINK (how to use css ,atrributes,style in css)