This is a migrated thread and some comments may be shown as answers.

WebForm_DoPostBackWithOptions

3 Answers 591 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
mathieu cupryk
Top achievements
Rank 1
mathieu cupryk asked on 17 Feb 2010, 01:39 AM

 

<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ctrlUserProfilePics.ascx.cs" 
    Inherits="OmegaLove.Web.UI.ctrlUserProfilePics" %> 
<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %> 
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajaxToolkit" %> 
<%@ Register Src="ctrlUserProfilePicsText.ascx" TagName="ctrlUserProfilePicsText" 
    TagPrefix="uc1" %> 
 
 
 
<div class="accordionContent" style="display: block;">  
    <div class="boxContent">  
        <div style="padding-left: 15px; padding-right: 15px;">  
            <uc1:ctrlUserProfilePicsText ID="ctrlUserProfilePicsText" runat="server" /> 
            <table cellspacing="2" cellpadding="0" width="800" border="0">  
                <tbody> 
                    <tr> 
                        <td align="center" colspan="3">  
                            <%--<asp:Image ID="ImgFullSize" runat="server" Style="border: 4px solid white" ImageUrl="~/Images/NoPhoto.jpg" 
                                CssClass="photo_198" />--%> 
                        </td> 
                    </tr> 
                    <tr> 
                        <td valign="middle" align="center" width="40">  
                            &nbsp;  
                        </td> 
                        <td align="center">  
                            <asp:UpdatePanel ID="UpdatePanel1" runat="server">  
                                <ContentTemplate> 
                                    <asp:DataList ID="DLThumbnails" runat="server" DataKeyField="img_id" RepeatDirection="Horizontal" 
                                        CellSpacing="5" CellPadding="0" HorizontalAlign="Center" CssClass="view" RepeatColumns="5" 
                                        Item-BorderWidth="1" Item-BorderColor="#c0c0c0" OnItemDataBound="DLThumbnails_ItemDataBound" 
                                        OnItemCommand="DLThumbnails_ItemCommand">  
                                        <ItemTemplate> 
                                            <table cellspacing="7" cellpadding="0" border="0">  
                                                <tr valign="top">  
                                                    <td> 
                                                        <span class="verdana12"><b>Main profile photo</b></span<span id="top_1"></span> 
                                                    </td> 
                                                </tr> 
                                                <tr height="150" valign="top">  
                                                    <td> 
                                                        <div style="position: relative; height: 148px;">  
                                                            <asp:Image runat="server" ID="view_image" Width="118" Height="148" alt='Photo from Album Number <%# Eval("img_id") %>' /> 
                                                        </div> 
                                                        <br /> 
                                                        <asp:LinkButton ID="lnkRemove" runat="server" CommandArgument='<%#DataBinder.Eval(Container.DataItem, "img_id")%>' 
                                                            Text="Delete Photo" OnClick="DeleteImage"></asp:LinkButton> 
                                                        <%--      <asp:LinkButton ID="delete" runat="server" Text="Delete Photo" CommandName="Delete" 
                                                            CommandArgument='<%#DataBinder.Eval(Container.DataItem, "img_id")%>'></asp:LinkButton>--%> 
                                                        <%-- <asp:ImageButton ID="ImgButtonDeletePhoto" runat="server" ImageUrl="~/Images/Buttons/delete-image.gif" 
                                                    Visible="true" OnClientClick="ImgButtonDeletePhoto_Click" />--%> 
                                                    </td> 
                                                </tr> 
                                            </table> 
                                        </ItemTemplate> 
                                        <AlternatingItemStyle BackColor="White" /> 
                                        <ItemStyle Width="20%" BackColor="#EFF3FB" /> 
                                        <SelectedItemStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" /> 
                                        <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" /> 
                                        <FooterTemplate> 
                                        </FooterTemplate> 
                                    </asp:DataList> 
                                </ContentTemplate> 
                                <Triggers> 
                                    <asp:AsyncPostBackTrigger ControlID="DLThumbnails" /> 
                                </Triggers> 
                            </asp:UpdatePanel> 
                            <div id="AlertDiv" class="AlertStyle">  
                            </div> 
                            <%--  <asp:Panel ID="Panel1" runat="server" Visible="false" CssClass="nullpanel">  
                                        There are currently no pictures in your profile.</asp:Panel> 
                                    <br /> 
                                    <br />--%> 
                        </td> 
                        <td valign="middle" align="center" width="40">  
                            &nbsp;  
                        </td> 
                    </tr> 
                    <tr> 
                        <td> 
                            &nbsp;  
                        </td> 
                        <td align="center">  
                            <%--<asp:Label ID="lblCurrentPage" runat="server" Font-Names="Trebuchet MS" Font-Size="12px" 
                                ForeColor="White"></asp:Label>--%> 
                        </td> 
                        <td> 
                            &nbsp;  
                        </td> 
                    </tr> 
                </tbody 
When I go over a link button
the following appears:

javascript:WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions("ctl00$ctl00$cph1$cph1$RadPanelBar5$i0$i0$ctrlUserProfilePics$DLThumbnails$ctl01$lnkRemove", "", true, "", "", false, true))

3 Answers, 1 is accepted

Sort by
0
Reza
Top achievements
Rank 1
answered on 23 Aug 2010, 05:14 AM
My instance of Sitefinity renders buttons and link buttons with the same javascript code in the onlclick event and the problem is, the buttons and links do not work.

The funny thing is, it works on my local machine but when getting ConnectionString to point to another database (of a separate instance of Sitefinity) the problem occurs. It sounds like something in the settings or installation configuration of Sitefinity would determine how the buttons render.

I know you logged this problem some months ago and I am facing it now, did you have any chance to figure it out?

Cheers,
Reza
0
Bodevain Svensson
Top achievements
Rank 1
answered on 23 Aug 2010, 04:25 PM
Mathieu seems to be having issues with a link button inside MS UpdatePanel (I see no Telerik controls) - most probably he contacted the MS guys in the ASP.NET forums.

Reza, for your case I would post either in the Sitefinity forums or contact Telerik Support folks using the ticketing system.

Bodevain
0
Reza
Top achievements
Rank 1
answered on 24 Aug 2010, 12:20 AM
Thanks for your quick reply. My case is resolved as I found out there was a validator control on the page out of nowhere and it was failing so any postback submission would fail.
Tags
General Discussions
Asked by
mathieu cupryk
Top achievements
Rank 1
Answers by
Reza
Top achievements
Rank 1
Bodevain Svensson
Top achievements
Rank 1
Share this question
or