473,698 Members | 2,213 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 7068
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
1670
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
17129
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
2452
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
1659
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
6893
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
5999
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
7388
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
1454
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
4003
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
8673
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8601
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
9156
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
8860
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7716
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...
0
4614
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3043
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
2327
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
1998
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.