473,721 Members | 1,930 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Populate List or Combo Box with file names in a folder

MS
I would like to be able to examine a folder, and populate a List Box or
Combo Box with the files that are in it.

How would you go about doing this?

The reason is that I would like the user to be able to restore a list of
tables from specifically selected files that periodically get "backed up"

Cheers!
Nov 13 '05 #1
3 7076
I think if you are using Access 2002 or later, your listbox / combobox has
an AddItem method, which will let you add rows to it.
Look at the Dir() function to return the file names from a folder.

"MS" <Em***@Myemail. com> wrote in message
news:F0******** ************@ne ws-server.bigpond. net.au...
I would like to be able to examine a folder, and populate a List Box or
Combo Box with the files that are in it.

How would you go about doing this?

The reason is that I would like the user to be able to restore a list of
tables from specifically selected files that periodically get "backed up"

Cheers!

Nov 13 '05 #2
MS

"MacDermott " <ma********@nos pam.com> wrote in message
news:1m******** *******@newsrea d2.news.atl.ear thlink.net...
I think if you are using Access 2002 or later, your listbox / combobox has
an AddItem method, which will let you add rows to it.
Look at the Dir() function to return the file names from a folder.

"MS" <Em***@Myemail. com> wrote in message
news:F0******** ************@ne ws-server.bigpond. net.au...
I would like to be able to examine a folder, and populate a List Box or
Combo Box with the files that are in it.

How would you go about doing this?

The reason is that I would like the user to be able to restore a list of
tables from specifically selected files that periodically get "backed up"

Cheers!


Sorry, forgot to say we're talkin' A97.
Nov 13 '05 #3
> Sorry, forgot to say we're talkin' A97.

This demonstrates a technique that works for A97:

http://groups-beta.google.com/group/...0410ec42d02213

It is easy to modify so that all the filenames in a directory are
listed instead of those ending in txt.

James A. Fortune

Nov 13 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1671
by: Joyce | last post by:
The XML Schema design problem to solve is as follows: We have 2 combo boxes to populate from schema data, let's say: 1. States 2. Cities (and this one gets populated depending on the choice of the state) The event management is no problem, the question is, how do we build our XML Schema (that's going to contain the data for both states and
5
17131
by: Mark | last post by:
How can I populate a listbox with a list of the filenames in a certain folder? Can a query retrieve the filenames from a folder? Thanks! Mark
5
2453
by: Filips Benoit | last post by:
Dear all, How can i populate a combo with the field-caption-names of 1 table? Thanks Filip
1
1661
by: davidgordon | last post by:
Hi, I have a form with 2 combo boxes. I am not using them in the usual way, please read on: In the 'Form Load' event, I have: _______________________________________ dim folderspec as string
3
6897
by: Yi Chen | last post by:
We have a drop down list on a PHP page, with several product names, and when people click one item, we will refresh the same page with the product name as parameter, and in turn we want to include a HTML file into the content area of the same page. I know it is recommended to put everything into database, but we want the web site to be very "portable", so the drop-downlist and the content should both in text files. Let's say the...
1
6001
by: freekedoutfish | last post by:
Hi. New member here Im sat at work, pounding my head off the desk because this tiny bit of simple code refuses to work. The sub is intended to pull data from the "companyname" column in the "cmSelectAllCompanyNames" table, and put all the company names it finds into the "cbFilterCompanyName" combo box. Now the confusing aspect is this: It works!!!
11
7393
by: eureka | last post by:
Hi All, I'm training in Servlets, JSP and JavaScript, I have a web page in which there's a "StudentName" textbox and below it is a "Names" Dropdown list. Initially the Textbox is empty and the Dropdown doesnt have any items.. The requirement is that as soon as one goes on typing the letters in the StudentName-textbox the corresponding matching names have to appear
1
1456
by: OblongPlatypus | last post by:
Hi, I am fairly new to VB and I am using Visual Studio 2005. I am currently trying to make a simple programme to search a database using 2 different combo boxes to define the search parameters. The database is a list of car manafacturers, models and information about tow bar's (part number etc..). I want the first combo box to be populated with the manafacturer names and that selection to populate the second combo box with the relevant car...
5
4006
by: giandeo | last post by:
Hello Experts. Could you find a solution for this problem please! I have the following tables in Access Database Table Name: origin Fields Names: country, countrycode Table Name: make Fields Names: countrycode, make
0
8730
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9367
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9215
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8007
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6669
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4484
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4753
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3189
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2576
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.