title: Save pictures in a folder and display them in a gridview
body: <p>I have these controls on my page:</p>
  
  <blockquote>
  <pre><code>&lt;p&gt;
      &lt;asp:FileUpload ID="FileUpload1" runat="server" /&gt;
  &lt;/p&gt;
  &lt;p&gt;
      &lt;asp:Button ID="Button1" runat="server" Text="Button" /&gt;
  &lt;/p&gt;
  &lt;asp:GridView ID="GridView1" runat="server"&gt;
  &lt;/asp:GridView&gt;
  </code></pre>
  </blockquote>
  
  <p>There is a foolder with the name "UplPics" in my solution explorer and the below VB.NET code in my Defaul.aspx page:</p>
  
  <pre><code>Imports System.IO
  
  Partial Class _Default
  
   Inherits System.Web.UI.Page
  
   Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
       If Not IsPostBack Then
           Dim filePaths As String() = Directory.GetFiles(Server.MapPath("~/UplPics/"))
           Dim files As New List(Of ListItem)()
           For Each filePath As String In filePaths
               Dim fileName As String = Path.GetFileName(filePath)
               files.Add(New ListItem(fileName, "~/UplPics/" + fileName))
           Next
           GridView1.DataSource = files
           GridView1.DataBind()
       End If
  
   End Sub
  
   Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
       If FileUpload1.HasFile Then
           Dim fileName As String = Path.GetFileName(FileUpload1.PostedFile.FileName)
           FileUpload1.PostedFile.SaveAs(Server.MapPath("~/UplPics/") + fileName)
           Response.Redirect(Request.Url.AbsoluteUri)
       End If
  
   End Sub 
  End Class
  </code></pre>
  
  <p>When I upload and load my web page it does not show the pictures but show the URL of each picture, how could I show the pictures instead of their URL?</p>