Showing posts with label box. Show all posts
Showing posts with label box. Show all posts

Wednesday, March 28, 2012

Multiple UpdateProgress on a page?

My UpdateProgress Panel gets fired when I use my modalpopup box. Is there anyway for the modal popup to have its own progress and not trigger the one already defined on the page?

If you define aasp:UpdateProgressin a web form and specify an AssociatedUpdatePanelID?property for it, it will be triggered?and?display?the?
AssociatedUpdatePanel when you press any control in the web form.
Try the following codes and check if it works in your project.
<script type="text/javascript">
var prm = Sys.WebForms.PageRequestManager.getInstance();
prm.add_initializeRequest(InitializeRequest);
prm.add_endRequest(EndRequest);
var postBackElement;
function InitializeRequest(sender, args) {
if (prm.get_isInAsyncPostBack())
{
args.set_cancel(true);
}
postBackElement = args.get_postBackElement();
if (postBackElement.id == 'ButtonTrigger')
{
$get('UpdateProgress1').style.display = "block";
$get('ButtonTrigger').style.display = "none";
}
}
function EndRequest (sender, args) {
if (postBackElement.id == 'ButtonTrigger')
{
$get('UpdateProgress1').style.display = "none";
$get('ButtonTrigger').style.display = "block";
}
}
function AbortPostBack() {
if (prm.get_isInAsyncPostBack()) {
prm.abortPostBack();
}
}
</script
<div>
<asp:Button ID="ButtonTrigger" runat="server" Text="Refresh Panel 5" OnClick="Button_Click" />
<asp:UpdatePanel ID="UpdatePanel5" runat="server">
<ContentTemplate>
<%=DateTime.Now.ToString() %> <br />
The trigger for this panel
causes the UpdateProgress to be displayed
even though the UpdateProgress is associated
with panel 2.
<br />
</ContentTemplate>
<Triggers>
<asp:AsyncPostBackTrigger ControlID="ButtonTrigger" />
</Triggers>
</asp:UpdatePanel>
<asp:UpdatePanel ID="UpdatePanel6" UpdateMode="Conditional" runat="server">
<ContentTemplate>
<%=DateTime.Now.ToString() %> <br />
<asp:Button ID="Button2" runat="server" Text="Refresh Panel 6" OnClick="Button_Click"/>
</ContentTemplate>
</asp:UpdatePanel>
<span style="display: inline-block;">
<asp:UpdateProgress ID="UpdateProgress1" runat="server">
<ProgressTemplate>
<asp:Image ID="Image1" runat="server" ImageUrl="~/images/airplane.bmp" />
</ProgressTemplate>
</asp:UpdateProgress>
</span>
</div>
Wish the above can help you.

Monday, March 26, 2012

Mutiple update panel - How to bind trigger event for control which is inside of other upda

Hi,

Thanks for visitng my problem.

I have 3 update panels. in first update panel U1 I have text box T1 and drop dwonbox D1.In second update panel U2 i have only drop down box D2. and in third update panel U3 i have a treeview T1.

I want that When I change selection of D1 in U1, it triiger events for D2 in U2 and T1 in U3. But when I try to bid U2 with D1 change event it does not show show D1 namein triiger control names. Rather it shows U1 panel name. Sam case is for T1 in U3. So my qiestion is : "HOW TO BIND TRIGGER WITH CONTROL WHICH IS INSIDE OF OTHER UPDATE PANEL?"

Looking for your Help.

Thanks,

John

Hi John,

I think the easiest solution would be to place one UpdatePanel around all three controls. If this doesn't work for you, perhaps you could post asmall code sample showing what you already tried.

Thanks,
Ted

Wednesday, March 21, 2012

Need Help in Ajax Dialog box loosing control

I have ajax dialog box for search data. When it opens dialog box it has a text box in which I can search and it populates the radio button list based on the search. When i select 1 record and hit submit it works on my dev box but on my production box when i click search it does not populate the radio button list. Does any one had similar kind of issue? and if yes can someone please tell me what to do to fix this..

Thanks

Hi,

Based on your description, I think is incurred by incorrect configuration on your production box since your application works fine on dev box.

Please make sure the ajax extension is installed on the production box, and the site is configured to asp.net 2.0.