English 中文(简体)
我如何从一个数据库中拿到BLOB值,将其储存在习惯物体中?
原标题:How do I take a BLOB value from a database and store it in a string in a custom object?

我正在利用一个有网格的更新小组,得出以下错误。

微软J类文字错误: Sys.WebForms.PageRequestManagerParserErrorException: 从服务器收到的电文不能平坦。 这一错误的共同起因是,通过呼吁作出反应来修改答复。 能够进行写作、反应过滤器、HttpModules或服务器跟踪。

我已经研究了这方面的所有“固定点”,其中似乎都没有工作。 它在页数上只打上了罚款,但在我点击我的“yn子”时,电网过程的一行(我可以看一看“javascript debug”),但在第一行处理后,我在这个行上发现了上述错误。

try { _this._webRequest.completed(Sys.EventArgs.Empty); } finally { if (_this._xmlHttpRequest != null) { _this._xmlHttpRequest.onreadystatechange = Function.emptyMethod; _this._xmlHttpRequest = null; } }

这里是我的网格。

 <asp:Button ID="btnSearch" runat="server" Text="Search" OnClick="btnSearch_Click" />
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
    <ContentTemplate>
        <table border="0" cellpadding="2" cellspacing="0" width="100%" id="Table3">
            <tr>
                <td width="100%">
                    <table border="0" cellpadding="0" width="100%" id="Table4">
                        <tr>
                            <td>
                                <span style="font-size: x-large;">Results</span>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left;">
                                <asp:Label ID="lblError" runat="server" ForeColor="Red"></asp:Label>
                                <asp:Label ID="lblCount" runat="server" ForeColor="Black"></asp:Label>
                            </td>
                            <td style="text-align: right;">
                                <asp:Label ID="lblCount2" runat="server" ForeColor="Black"></asp:Label>
                            </td>
                        </tr>
                        <tr>
                            <td colspan="2">
                                <asp:GridView Width="100%" ID="resultsGrid" AutoGenerateColumns="false" runat="server"
                                    AllowPaging="true" AllowSorting="true" PageSize="20" OnPageIndexChanging="gridView_PageIndexChanging"
                                    OnSorting="gridView_Sorting" PagerSettings-Position="TopAndBottom" PagerStyle-HorizontalAlign="Center">
                                    <Columns>
                                        <asp:TemplateField HeaderStyle-Width="2%" ControlStyle-Width="100%">
                                            <ItemTemplate>
                                                <%# Container.DataItemIndex + 1 + "." %>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField Visible="false" SortExpression="record_id">
                                            <ItemTemplate>
                                                <asp:Label ID="lblRecordID" runat="server" Text= <%# Eval("RecordID") %>  Visible="false"></asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderStyle-Width="7%" ControlStyle-Width="100%" HeaderText="Note Type"
                                            SortExpression="business_content_type_cd">
                                            <ItemTemplate>
                                                <asp:Label ID="lblNoteType" runat="server" Text= <%# Eval("NoteType") %> ></asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderStyle-Width="10%" ControlStyle-Width="100%" HeaderText="Author"
                                            SortExpression="author_user_name">
                                            <ItemTemplate>
                                                <asp:Label ID="lblAuthor" runat="server" Text= <%# Eval("Author") %> ></asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderStyle-Width="7%" ControlStyle-Width="100%" HeaderText="Date"
                                            SortExpression="content_dttm">
                                            <ItemTemplate>
                                                <asp:Label ID="lblDate" runat="server" Text= <%# Eval("Date") %> ></asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField HeaderStyle-Width="60%" ControlStyle-Width="100%">
                                            <ItemTemplate>
                                                <asp:Label ID="lblData" runat="server" Text= <%# Eval("NoteContent") %> ></asp:Label>
                                                <asp:HyperLink ID="linkMore" runat="server" />
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:TemplateField SortExpression="size" Visible="false">
                                            <ItemTemplate>
                                                <asp:Label ID="lblSize" runat="server" Text= <%# Eval("Size") %>  Visible="false"></asp:Label>
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                    </Columns>
                                </asp:GridView>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left;">
                                <asp:Label ID="lblCount3" runat="server" ForeColor="Black"></asp:Label>
                            </td>
                            <td style="text-align: right;">
                                <asp:Label ID="lblCount4" runat="server" ForeColor="Black"></asp:Label>
                            </td>
                        </tr>
                    </table>
                </td>
            </tr>
        </table>
    </ContentTemplate>
    <Triggers>
        <asp:AsyncPostBackTrigger ControlID="btnSearch" EventName="Click" />
    </Triggers>
</asp:UpdatePanel>

我在这里完全 st,任何帮助都是巨大的。

我的AJAX从PatBug中的反应

14008|updatePanel|ctl00_ContentPlaceHolder_UpdatePanel1|
        <table border="0" cellpadding="2" cellspacing="0" width="100%" id="Table3">
            <tr>
                <td width="100%">
                    <table border="0" cellpadding="0" width="100%" id="Table4">
                        <tr>
                            <td>
                                <span style="font-size: x-large;">Results</span>
                            </td>
                        </tr>
                        <tr>
                            <td style="text-align: left;">
                                <span id="ctl00_ContentPlaceHolder_lblError" style="color:Red;"></span>
                                <span id="ctl00_ContentPlaceHolder_lblCount" style="color:Black;">5 found</span>
                            </td>
                            <td style="text-align: right;">
                                <span id="ctl00_ContentPlaceHolder_lblCount2" style="color:Black;">1 to 5 of 5</span>
                            </td>
                        </tr>
                        <tr>
                            <td colspan="2">
                                <div>
<table cellspacing="0" rules="all" border="1" id="ctl00_ContentPlaceHolder_resultsGrid" style="width:100%;border-collapse:collapse;">
    <tr>
        <th scope="col" style="width:2%;">&nbsp;</th><th scope="col" style="width:7%;"><a href="javascript:__doPostBack( ctl00$ContentPlaceHolder$resultsGrid , Sort$business_content_type_cd )">Note Type</a></th><th scope="col" style="width:10%;"><a href="javascript:__doPostBack( ctl00$ContentPlaceHolder$resultsGrid , Sort$author_user_name )">Author</a></th><th scope="col" style="width:7%;"><a href="javascript:__doPostBack( ctl00$ContentPlaceHolder$resultsGrid , Sort$content_dttm )">Date</a></th><th scope="col" style="width:60%;">&nbsp;</th>
    </tr><tr>
        <td>
                                                1.
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl03_lblNoteType" style="display:inline-block;width:100%;">General</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl03_lblAuthor" style="display:inline-block;width:100%;">LISA WHIPKEY</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl03_lblDate" style="display:inline-block;width:100%;">3/17/2011 4:08:15 PM</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl03_lblData" style="display:inline-block;width:100%;">HIS ROAD WAS CONTROLLED BY A STOP SIGN. HE NEEDED TO MAKE A LEFT ON TO PINEAND THEN MAKE A LEFT AGAIN QUIKELY INTO A PARKING LOT TO THE LEFT.         HE LOOKED LEFT AND THE INSURED SAW A CAR THAT WAS COMING AT HIM. HE WAS    WAITING FOR THE CAR TO PASS BUT THE CAR THAT WAS COMING AT HIM TURNED INTO THE PARKING LOT THAT HE NEEDED TO TURN INTO. THE INSURED WAS AT THE STOP   SIGN FOR APPROX 20 TO 30 SECONDS. THE LIGHTS WERE GLARINIG ON THE ROAD.��������������</span>
                                                <a id="ctl00_ContentPlaceHolder_resultsGrid_ctl03_linkMore" style="display:inline-block;width:100%;"></a>
                                            </td>
    </tr><tr>
        <td>
                                                2.
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl04_lblNoteType" style="display:inline-block;width:100%;">General</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl04_lblAuthor" style="display:inline-block;width:100%;">LISA WHIPKEY</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl04_lblDate" style="display:inline-block;width:100%;">3/17/2011 4:07:41 PM</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl04_lblData" style="display:inline-block;width:100%;">CALLED THE INSURED MIKE CHALLEEN AT 406-529-5534 LVM CALLED THE CELL OF    INSD MIIKE CHALLEEN AT 406-529-5534 CONFIRMED R/S FROM THE INSURED.                                                                                   THE INSD DRIVING A FRIENDS VEHICLE.  THE INSD WAS STAYING IN MISSOULA FOR ACOUPLE OF DAYS FOR WORK. HE MET MIKE BROWN FOR DINNER AND INSD MIKE HALLEENJUST PURHCES A NEW 2001 CAMARO SS/SP  VIN - 2G1FT1EW0A9123754, RED IN COLORMIKE BROWN WAS INTERESTED IN PURCHASING ONE AND WANTED TO DRIVE IT FOR THE EVENING. HE AGREED AND SO THE INSURED DROVE MIKE BROWNS VEHICLE WHICH WAS AFORD TRUCK DESIEL 4 DR. TWO TONE PU LONG BED. MIKE BROWN DROVE HIS VEHICLE 2010 CAMARO. SO IN THE MORNING GOING TO WORK AT APPROX 7:30 AM THIS MORNING THE INSURED WORKED OUT AHEAD A SCHEDULE FROM THE HOTEL DECIDED TO GO IN   EARLY.                                                                                                                                                TRAVELING DOWN PATTEE N/B</span>
                                                <a id="ctl00_ContentPlaceHolder_resultsGrid_ctl04_linkMore" href="logNoteDetail.aspx?noteID=0" target="_blank" style="display:inline-block;width:100%;">more</a>
                                            </td>
    </tr><tr>
        <td>
                                                3.
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl05_lblNoteType" style="display:inline-block;width:100%;">General</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl05_lblAuthor" style="display:inline-block;width:100%;">LISA WHIPKEY</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl05_lblDate" style="display:inline-block;width:100%;">3/17/2011 3:58:44 PM</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl05_lblData" style="display:inline-block;width:100%;">GENERAL NOTE TESTING 123456GGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG G  G  G  G GG G G G G G G G G G GGGGGGGG G   G  G G  G   G  G  G  G  G G G  G  G G  G GGG G G FGHJH HFDGKL HFG JDFHGKJDHFG DHFG FH KGHDF GHFKJDHGKH DGHFK   HF    STOPPED THE CK FOR 100,000, SCOTT G. IS NOW DEFENDING THE INSD AND NOT PROTECTING US. I ISSUED OUT THE PAYMENT AND THEN HE HAD THE CK. NOW REVERSED   AND WILL NOT RELEASE THE FUNDS TO P/C AND WAS HOLDING FOR AN EXCHANGE OF   PAYMENT.                                                                                                                                              BOHXXX, SIMPXXX AND TRAXXXL PC                                             283 WEST FRONT STREET, SUITE 201                                           MISSOULA, MONTANA 59802 (MISSOULA CO.)                                     PHN:  406-532-7800                                                         HTTP://WWW.BSTLAWFIRM.COM                                                                           </span>
                                                <a id="ctl00_ContentPlaceHolder_resultsGrid_ctl05_linkMore" href="logNoteDetail.aspx?noteID=0" target="_blank" style="display:inline-block;width:100%;">more</a>
                                            </td>
    </tr><tr>
        <td>
                                                4.
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl06_lblNoteType" style="display:inline-block;width:100%;">General</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl06_lblAuthor" style="display:inline-block;width:100%;">LISA WHIPKEY</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl06_lblDate" style="display:inline-block;width:100%;">3/10/2011 3:55:25 PM</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl06_lblData" style="display:inline-block;width:100%;">PLAN OF ACTION                                                             IUY                                                                        UYUY KJHKJ                                                                 HKJH                                                                       LKJHKJLH                                                                   JKHKJH                                                                     JKH                                                                        KJHJ                                                                       KH                                                                         JKH                                                                        LJ                                                                         HJK                                                                        HLJ                                                                        HLHJ                     </span>
                                                <a id="ctl00_ContentPlaceHolder_resultsGrid_ctl06_linkMore" href="logNoteDetail.aspx?noteID=0" target="_blank" style="display:inline-block;width:100%;">more</a>
                                            </td>
    </tr><tr>
        <td>
                                                5.
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl07_lblNoteType" style="display:inline-block;width:100%;">General</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl07_lblAuthor" style="display:inline-block;width:100%;">LISA WHIPKEY</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl07_lblDate" style="display:inline-block;width:100%;">3/10/2011 3:53:57 PM</span>
                                            </td><td>
                                                <span id="ctl00_ContentPlaceHolder_resultsGrid_ctl07_lblData" style="display:inline-block;width:100%;">DFSHK                                                                      HKJH                                                                       KJHK HKJ                                                                   OU OI                                                                      UOIU                                                                       U OU O                                                                     UY                                                                         UY                                                                         Y                                                                          Y                                                                          OIJ                                                                        J                                                                          N                                                                          L                        </span>
                                                <a id="ctl00_ContentPlaceHolder_resultsGrid_ctl07_linkMore" href="logNoteDetail.aspx?noteID=0" target="_blank" style="display:inline-block;width:100%;">more</a>
                                            </td>
    </tr>
</table>

5 found 1 to 5 of 5

我在本法典中所做的是,将BLOB值从一个数据库转换为一种在习惯物体中储存。 似乎发生的情况是,在扼杀结束时,有奇怪的特点。 在这方面,我正在做些什么来转换数据。

     byteBLOBData = (Byte[])(row[3]);
                        row["data"] = System.Text.Encoding.UTF8.GetString(byteBLOBData);
最佳回答

辩论这些问题的最佳途径之一是检查AJAX在大火中的反应,看看看看属于哪类的微粒。 如果你用日本宇宙航空研究开发机构的答复复制件/剪辑来更新你的问题,我可以告诉你,哪一部分时间没有。 然后,你知道,在你的服务器边代码中可以找到什么。

问题回答

暂无回答




相关问题
Anyone feel like passing it forward?

I m the only developer in my company, and am getting along well as an autodidact, but I know I m missing out on the education one gets from working with and having code reviewed by more senior devs. ...

How to Add script codes before the </body> tag ASP.NET

Heres the problem, In Masterpage, the google analytics code were pasted before the end of body tag. In ASPX page, I need to generate a script (google addItem tracker) using codebehind ClientScript ...

Transaction handling with TransactionScope

I am implementing Transaction using TransactionScope with the help this MSDN article http://msdn.microsoft.com/en-us/library/system.transactions.transactionscope.aspx I just want to confirm that is ...

System.Web.Mvc.Controller Initialize

i have the following base controller... public class BaseController : Controller { protected override void Initialize(System.Web.Routing.RequestContext requestContext) { if (...

Microsoft.Contracts namespace

For what it is necessary Microsoft.Contracts namespace in asp.net? I mean, in what cases I could write using Microsoft.Contracts;?

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签