How to Fill Combobox with 18 files of a predefined directory?

Posted on 2005-04-09
Last Modified: 2010-04-05
Hi Folks!

After browsing through the solution database I decided to drop my question here anyway.
My combobox should wrap its arms around one predefined directory in which 18 ini files reside, no subdirs just those 18 files.

Amaze me :) > I'm curious as to how many lines of code this will add to my project and that in fact is the reason I decided to post it  instead of grabbing an answer from the database solutions.


Question by:PeterdeB
    LVL 11

    Accepted Solution

    Drop a TFileListBox on your form, set its visible property = false;

     FileListBox1.Directory:=  YourDirectory

     FileListBox1.Mask:= '*.*;  //or set it to what ever extension of files you want


    Hope this helps!


    Author Comment

    Ok tnx Shane, fast as ever :)

    I'm off to Delphi now but will return!



    Author Comment

    Why even bother to check whether it works, when it always does!

    Muchos Gracias!


    Peter :)

    Featured Post

    What Security Threats Are You Missing?

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Join & Write a Comment

    This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
    Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
    This video is in connection to the article "The case of a missing mobile phone (". It will help one to understand clearly the steps to track a lost android phone.
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

    728 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    17 Experts available now in Live!

    Get 1:1 Help Now