Indigo Rose Software

Professional Software Development Tools

 
Results 1 to 3 of 3
  1. #1
    Join Date
    Nov 2006
    Posts
    25

    querying access databases

    Hi guys, quick question for you. I have a access database and right now its not doing what i want it to do. I would like it to add the contents of column "Question" to listbox names "answers" but i need it to do it depending on the Model selected from a combobox. I cant tell what is wrong in this code, it seems the string that is pulling the text from the combobox may be stopping the query... any ideas on this?

    Model = ComboBox.GetText("Model");


    strDbPathAndName = "AutoPlay\\Docs\\Customer Service.mdb"
    DBOpen("Provider=Microsoft.Jet.OLEDB.4.0; Data Source="..strDbPathAndName)

    DBExec("select "..Model.." from Questions")
    t = DBRow()
    while t.Question do
    ListBox.AddItem("Answers", t.Question.. "");
    t = DBRow()
    end



    thanks

  2. #2
    Join Date
    Apr 2004
    Location
    Vancouver, Canada
    Posts
    1,790
    Try this

    Code:
    DBExec("SELECT Question FROM Questions WHERE Model = '"..Model.."'" )
    Dermot

    I am so out of here

  3. #3
    Join Date
    Nov 2006
    Posts
    25
    Dermot
    thanks!! it worked!!
    Dermot to the rescue!!


Similar Threads

  1. How to convert access database to sqlite database.
    By sside in forum AutoPlay Media Studio 5.0
    Replies: 2
    Last Post: 07-22-2008, 07:44 PM
  2. INFO: Microsoft Data Access Components 2.8 Runtime Notes
    By Desmond in forum Setup Factory 6.0 Knowledge Base
    Replies: 0
    Last Post: 11-28-2003, 08:20 AM
  3. access 2000 run time
    By jennersc in forum AutoPlay Media Studio 4.0
    Replies: 0
    Last Post: 07-31-2003, 12:09 PM
  4. INFO: Installing the Microsoft Access Runtime Engine
    By Support in forum Setup Factory 6.0 Knowledge Base
    Replies: 0
    Last Post: 10-11-2002, 01:01 PM

Posting Permissions

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