Forums
New posts
Search forums
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
C# Community
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
VB.NET
VB.NET General Discussion
Searching Hard Disk For Files..
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
[QUOTE="Sachith, post: 133934, member: 32409"] I am going to develop a antivirus software and i want to scan the files.. so i want to get the files one by one into a [U]Label[/U] I Already use this code to get add the files to a listbox But It did not Help For me... Because it is adding Whole Files to a List Box at Ones.. [CODE] Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click rslts = New List(Of String) foo(Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)) ListBox1.Items.Clear() ListBox1.Items.AddRange(rslts.ToArray) End Sub Dim rslts As List(Of String) Private Sub foo(ByVal aDir As String) Try Dim di As New IO.DirectoryInfo(aDir) Dim aryFiles() As IO.FileInfo = di.GetFiles("*.*") Dim aryDirs() As IO.DirectoryInfo = di.GetDirectories() For Each fi As IO.FileInfo In aryFiles rslts.Add(fi.FullName) Next For Each d As IO.DirectoryInfo In aryDirs foo(d.FullName) Next Catch ex As Exception End Try End Sub[/CODE] If Enyone Know How To Do this.. Please Help Me.. I Been Searching For this Since last Month.. Thanks.. [/QUOTE]
Insert quotes…
Verification
Post reply
VB.NET
VB.NET General Discussion
Searching Hard Disk For Files..
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.
Accept
Learn more…
Top
Bottom