Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 474
  • Last Modified:

How to get more filenames from FileListBox1 to Edit1 ?

I want to make an program, that selects some files in a FileListBox1 and give the output to an Edit1. The problem is  if I select more than 1 file, the Edit1 displays only one filename. How do I get the other ones, Without selecting all the files one at a time, must I put the whole FileListBox1 into a string ?
0
CyberChild
Asked:
CyberChild
1 Solution
 
JimBob091197Commented:
You have to write a for loop to go through the list of files:
for i := 0 to FileListBox.Items.Count - 1 do
  if (FileListBox.Selected[i]) then
    Edit1.Text := Edit1.Text + ' ' + FileListBox.Items[i];

JB
0
 
CyberChildAuthor Commented:
Thanks.

0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now