Try Dim sql As String = "SELECT PHOTO FROM IMAGE WHERE " sql += "ID='" & txtID.Text & "'" cmd = New OracleCommand(sql, Con) ds = New DataSet da = New OracleDataAdapter(cmd) Try If Con.State = ConnectionState.Closed Then Con.Open() End If Catch ex As Exception Response.Write(ex.Message) Exit Sub End Try da.Fill(ds, "IMAGE") gvImages.DataSource = ds gvImages.DataBind() If Con.State = ConnectionState.Open Then Con.Close() End If Dim filepath As String = Server.MapPath(".\App_Data\temp\") Dim fullpath As String = filepath & "\" If Not (System.IO.Directory.Exists(fullpath)) Then System.IO.Directory.CreateDirectory(fullpath) End If Dim path As String = fullpath & lblblob.Text Image1.ImageUrl = path Catch ex As Exception Response.Write(ex.Message) End Try
gvImages.DataSource = ds
gvImages.DataSource = ds.Tables(0)
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)