locked
Problem on displaying blob data to screen RRS feed

  • Question

  • User-234026806 posted

    Hi There;

    I have a picture content in a blob area in PICTURE_TABLE table in oracle. Its name is SPEC_PIC and its type is blob. I have read the content of it in a dataset, and I want to print it via a gridview. Here is the structure of the gridview:

    <asp:GridView ID="myGrid" runat="server" AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" CssClass="grid"
    EmptyDataText="no data  !!!">
    
     <AlternatingRowStyle CssClass="odd" />
     <PagerStyle CssClass="footer" />
        <columns>
        <asp:boundfield datafield="PICT_ID" HeaderText="Picture id" />
        <asp:BoundField DataField="SPEC_PIC" HeaderText="Large Photo File" />
                                                    </columns>
                                              </asp:GridView>
    
    


    and this is the code behind contents:

       myGrid.DataSource = result;
            myGrid.DataBind();
            myGrid.Visible = true;
            myGrid.BackColor = Color.Yellow;

    When I run the code, I can not see the picture, I can only see the type name of the blob. I exactly see the visual picture. How can I handle this?

    Thanks in advance.

    Wednesday, November 28, 2012 8:27 AM

Answers

  • User269602965 posted

    BLOB is binary data and must be streamed to a compatible MIME format to show in a gridview.

     

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, November 29, 2012 9:53 PM

All replies

  • User269602965 posted

    BLOB is binary data and must be streamed to a compatible MIME format to show in a gridview.

     

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, November 29, 2012 9:53 PM
  • User-234026806 posted

    So, there is no way to display it directly to the screen as far as I understand, right?

    Thanks.

    Monday, December 3, 2012 2:30 AM