|
-
October 4th, 2001, 09:58 AM
#1
load .dbf file into a listbox
I want to load a single dbase file into a listbox. Any suggestions would be great! Thanks.
-
October 4th, 2001, 10:04 AM
#2
Re: load .dbf file into a listbox
Create a recordset for the field(s) that you need and enter it to the listbox.
List1.AddItem rs!Field1 & " " & rs!Field2
If you need a connection string for dbase, let me know
Iouri Boutchkine
[email protected]
-
October 4th, 2001, 10:17 AM
#3
Re: load .dbf file into a listbox
Thanks for the tip. I know how to create a connection for a database that stays in one place. But my problem is that I want to allow the user to specify where the .dbf file is stored.
For example, the user is asked to specify where the .dbf file is stored. Once they specify the location the .dbf files needs to be read into the listbox. I guess my question is how do I create a connection that is dynamic? My experience has only been with connecting to a database that stays in one place.
-
October 4th, 2001, 12:29 PM
#4
Re: load .dbf file into a listbox
On a button click bring an InputBox where user can enter the database path (or you can use Dialog Box). Assign path to the variable (DBFPATH) and then create the connection string
sConn = "Driver={Microsoft dBASE Driver (*.dbf)};DriverID=277;Dbq=" & DBFPATH & ";"
Here we go. We eill connect to the chosen location.
Iouri Boutchkine
[email protected]
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|