Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

form

Status
Not open for further replies.

lendbz

Programmer
Sep 26, 2005
19
US
Hi,

This is a simple thing? I am a beginner and not sure how i would go about doing it.. What i want to do is, I want to create a form in access that would

1) let you browse thru the file directory to select the file that you want
2) have a button that, after you select the file, when you hit the button it will import that file to a table in the database

what is the best way to go about doing that?? thanks :)

lenny
 
Actually lenny that's not such a 'simple' thing.

You'll need a less than common control on your form called a TreeView control.

It is available from the additional controls list in the standatd Access toolbox

You will then need to populate that toolbox with the folders on your drive ( from some pre-determined root ) and when each of them is opened you'll need to populate the next level down etc. until you get to the files that you want to display.



As an alternative you could just bring up the File-Open dialog box and allow the users to naviage using that to the file you want to load.
Then use the file name returned by that in an Update query run by the DoCmd.RunSQL command to populate the field in the table.



'ope-that-'elps.



G LS
spsinkNOJUNK@yahoo.co.uk
Remove the NOJUNK to use.
 
thanks!

How do i bring up the file open dialog box?

:)

lenny
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top