Results 1 to 2 of 2

Thread: How to Clear Datagrid

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Dec 2002
    Posts
    28

    How to Clear Datagrid

    dear All,
    how to clear datagrid ? is there anything like datagrid.clear command ?
    Pls advise ....TIA

    Jas

  2. #2
    Fanatic Member Armbruster's Avatar
    Join Date
    Sep 2002
    Location
    Maryland Heights, MO
    Posts
    857
    Set the recordsouce property for the datasource of your datagrid to an empty recordset then refresh the datagrid

    VB Code:
    1. Adodc1.Recordset = "SELECT * FROM Customers WHERE 1 = 2"
    2. DataGrid1.Refresh
    "Look! Up in the sky! It's a bird! It's a plane! It's Diaper-Head Boy! (there by my name!) Yes, Diaper-Head Boy, who disguised as my son, Seth, fights a never-ending battle for truth, justice and terrorizing my house!

    Resistance is futile, you will be compiled . . . Please!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width