File Directory ASP.Net Tutorial

<%@ Page Language="VB" %>
<%@ Import Namespace="System" %>
<%@ Import Namespace="System.IO" %>

    Public Sub Page_Load(Source As Object, E As EventArgs)
        PathPropertiesLiteral.Text = ""
    End Sub
    
    Public Sub ParsePath(Source As Object, E As EventArgs)
    
  Dim PropertyContainer As New StringBuilder()
    
        With PropertyContainer
            .Append("")
            .Append("Full Path")
            .Append("" & Path.GetFullPath(FileNameTextBox.Text) & "")
            .Append("Root Drive")
            .Append("" & Path.GetPathRoot(FileNameTextBox.Text) & "")
            .Append("Directory Path")
            .Append("" & Path.GetDirectoryName(FileNameTextBox.Text) & "")
            .Append("File Name")
            .Append("" & Path.GetFileName(FileNameTextBox.Text) & "")
            .Append("File Name (Without Extension)")
            .Append("" & Path.GetFileNameWithoutExtension(FileNameTextBox.Text) & "")
            .Append("File Extension")
            .Append("" & Path.GetExtension(FileNameTextBox.Text) & "")
            .Append("Temporary Filename")
            .Append("" & Path.GetTempFileName() & "")
            .Append("Temprary Filepath")
            .Append("" & Path.GetTempPath() & "")
            .Append("Directory Separator")
            .Append("" & Path.DirectorySeparatorChar & "")
            .Append("Alt Directory Separator")
            .Append("" & Path.AltDirectorySeparatorChar & "")
            .Append("Path Separator")
            .Append("" & Path.PathSeparator & "")
            .Append("Volume Separator")
            .Append("" & Path.VolumeSeparatorChar & "")
            .Append("Invalid Path Characters")
            .Append("" & Path.InvalidPathChars & "")
      .Append("")
            
        End With
  PathPropertiesLiteral.Text = PropertyContainer.ToString
    
    End Sub


  
    CookBook :: File Path Parsing
  
  
    
      

File Path Parser