| | |
Display System Directory
Please support our VB.NET advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Jun 2009
Posts: 269
Reputation:
Solved Threads: 53
try this:
vb Syntax (Toggle Plain Text)
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click treeDir.Nodes.Clear() CreateDirTree(Nothing, Environment.SystemDirectory) End Sub Private Sub CreateDirTree(ByVal fromNode As TreeNode, ByVal basePath As String) Dim newDir As TreeNode Dim subDir As String For Each singleDir As String In My.Computer.FileSystem.GetDirectories(basePath) subDir = My.Computer.FileSystem.GetName(singleDir) If fromNode Is Nothing Then newDir = treeDir.Nodes.Add(subDir) Else newDir = fromNode.Nodes.Add(subDir) End If CreateDirTree(newDir, My.Computer.FileSystem.CombinePath(basePath, subDir)) Next singleDir End Sub
![]() |
Similar Threads
- Completing a Loop to Search the Directory (Java)
- Persistent Compiler Error on a Directory System (Java)
- ASP How To Display Always The System Date (ASP)
- display the System.out.print msgs (Java)
- Program to display System date and Time in VC++ 6.0 (C++)
- Display System Time in VC++.net (Game Development)
- System 32 Coming Up at Startup (Viruses, Spyware and other Nasties)
- can't bring up display properties, XP-Pro (Windows NT / 2000 / XP)
- I've got Trojan.Holax... is this bad? (Viruses, Spyware and other Nasties)
Other Threads in the VB.NET Forum
- Previous Thread: Searching for a Solutions Manual
- Next Thread: tokenize text input
| Thread Tools | Search this Thread |
Tag cloud for VB.NET
.net 30minutes 2005 2008 access account application arithmetic array arrays basic binary bing button buttons c# center check checkbox code combobox component connectionstring convert crystalreport data database databasesearch datagrid datagridview design dissertation dissertations dissertationthesis dropdownlist excel file-dialog folder ftp generatetags google gridview hardcopy image images inline insert intel internet listview mobile monitor ms net networking output passingparameters peertopeervideostreaming picturebox picturebox1 plugin port print printing problem problemwithinstallation project reports" save searchbox searchvb.net select serial server soap sorting table tcp text textbox timer toolbox trim update updown user vb vb.net vb.netcode vb.netformclosing()eventpictureboxmessagebox vb2008 vbnet view visual visualbasic visualbasic.net visualstudio visualstudio2008 web wpf





