Click here to Skip to main content
15,915,093 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
hello i got a little problem
am trying to add multiple files to a listview,(i have already wrote the code to add multiple files at one),but when i add more than one files on the listview. I only see the first selected. i think the problem is that all the files fall into that same loop. is there anyway i could solve this problem?

thx in advance to any one who help

the code i used to add multiple files at once is : ofd.Multiselect = True
(ofd is define as open file dialog )
Posted
Comments
Mike Meinz 6-Mar-13 16:14pm    
Please show us your code so we can fully understand your question.

Are you using the openFileDialog.FileNames property to retrieve the filenames that are selected?
Maciej Los 6-Mar-13 16:15pm    
Please, be more specific and provide more details, especially code.
Sergey Alexandrovich Kryukov 12-Mar-13 15:59pm    
Please stop posting non-answers as "solution". It can give you abuse reports which eventually may lead to cancellation of your CodeProject membership.
Comment on any posts, reply to available comments, or use "Improve question" (above).
Also, keep in mind that members only get notifications on the post sent in reply to there posts.
—SA

1 solution

Hey I'm just wondering if there is any reason you can't navigate directly to the folder the files are in in you code and loop through all the files that you need and add them that way? I.e add all the files ending in .txt or .pdf or whatever... I can do a quick example if needed.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900