calling a funciton

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • vasan raju
    New Member
    • Mar 2012
    • 2

    calling a funciton

    I've a textbox and gridview in a from. in gridview i've loaded some data from sql. now I've a function in c sharp for search method. (ie)

    public void search()
    {
    SqlDataAdapter da = new SqlDataAdapter( "select * from mast_bloodgroup 2 where bloodgroup like'" + txtbldgrp.Text+ " % '", con);
    DataSet ds = new DataSet();
    da.Fill(ds);
    grdbldgrp.DataS ource = ds;
    grdbldgrp.DataB ind();
    }

    so when i type a letter and pressing enter button in that textbox.. the particular data shoulb be displayed in gridveiw which are data start with the letter that i typed in textbox
  • Ivan Voyager
    New Member
    • Mar 2012
    • 1

    #2
    Use parameters and specify DataMember.

    Comment

    Working...