vbMarkO Posted June 28, 2006 Posted June 28, 2006 How do I do this... This is what I have but it returns a list of the subdirectories but with the full paths to them as well. All I want is the Subdirectories within a Specific Directory. Dim dirArr() As String = System.IO.Directory.GetDirectories("C:\Visual Studio 2005\Projects\AddressBook\") For Each itm As String In dirArr tsCombo1.Items.Add(itm) Next So, what am I doing wrong? vbMarkO Quote Visual Basic 2008 Express Edition!
Administrators PlausiblyDamp Posted June 28, 2006 Administrators Posted June 28, 2006 try Dim dirArr() As String = System.IO.Directory.GetDirectories("C:\Visual Studio 2005\Projects\AddressBook\") For Each itm As String In dirArr tsCombo1.Items.Add(System.IO.Path.GetFileName(itm)) Next Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
vbMarkO Posted July 3, 2006 Author Posted July 3, 2006 Thanx this worked great!!! I have also found another way to do this but your code was much simpler. vbMarkO Quote Visual Basic 2008 Express Edition!
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.