CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4

Thread: VB And MsAcess

  1. #1
    Guest

    VB And MsAcess

    How can I run a query in Acess97 from Vb and return the result in a textbox on a form in Vb.
    Thanks.



  2. #2
    Join Date
    May 1999
    Posts
    3,332

    Re: VB And MsAcess

    Use DAO to access your Access database. Open it using the Opendatabase method, open the query using OpenQueryDef and move through the recordset using Movefirst/MoveNext methods. To move the contents of a certain field to a textbox, code something like
    Textbox1.Text = myRecordset.Fields(0).value



  3. #3
    Join Date
    Apr 1999
    Posts
    1

    Re: VB And MsAcess

    you can use the Ms SQL if you know how to use it, just dim a string for the SQL statement and send it
    the SQL qourrys function, for more information use the help fo the VB by loking for the SQL statement
    after this if you have any problem you can E-Mail me to [email protected] and I"ll send to you
    an example

    see you leter alegator


  4. #4
    Guest

    Re: VB And MsAcess

    hi!
    If you can send me your E-Mail,
    I can E-Mail you your program code that I wrote already.
    So you can use it. by copying it to your app.
    C U leter Allegator
    yechie



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

Featured