Results 1 to 3 of 3

Thread: ADO.Net with OLE Db

  1. #1

    Thread Starter
    Fanatic Member pvbangera's Avatar
    Join Date
    Sep 2001
    Location
    Mumbai, India
    Posts
    961

    Arrow ADO.Net with OLE Db

    hi,

    i am using ole db to connect access database through ado.net.

    after connection is made i want to populate all the tablenames in the database into my listbox on the form. and by default the 1st table should be opened and the data should get populated in the dbgrid.

    pls guide, its urgent.

  2. #2
    I wonder how many charact
    Join Date
    Feb 2001
    Location
    Savage, MN, USA
    Posts
    3,704

  3. #3

    Thread Starter
    Fanatic Member pvbangera's Avatar
    Join Date
    Sep 2001
    Location
    Mumbai, India
    Posts
    961
    Thanx for the link

    I use the following code to list all the tables in an mdb file.

    VB Code:
    1. dbConnection = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & DBName & ";Persist Security Info=False")
    2. dbConnection.Open()
    3. lstObjects.DataSource = dbTable

    The code is working fine. But I dont want to list all the columns (like Table_Catalog, Table_Schema, etc). I just want only 4 cols (Name, Description, Date created and Date modified)

    Also, after listing the tables, how to open a selected table from the list in DBGrid? I am finding ADO.Net very much confusing.

    Please guide.

    Regards

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