UpdatePanel Trigger Registration IMPOSSIBLE!

lunedì 29 marzo 2010 - 21.41

enricosoft Profilo | Newbie

Hi to all,
i have a big problem with a dynamic Imagebutton...
My scenario is the follow: i have a "master page" with scriptmanager and usercontrol containing a button.
When i click button,it open ModalPopUpExtender(also contained into the same usercontrol) that contains UpdatePanel child and also, into the update panel, there is a table that contains dynamic labels and ImageButtons!

The update Panel is setted to Conditional, so when i click an ImageButton, it don't lose any table rows, BUT this dynamic controls NOT REGISTERED to scriptmanager how "AsyncPostBackTrigger" so they didn't any postback!!!

I tryed to register it after the form INIT, but i fail:

1) my scriptManager is in the parent page and i don't to reach it to call "registerasyncpostbackcontrol"... how can i reach my parent control from my ascx?

2) if i understand all, i don't register Trigger to my Update Panel AFTER THE FORM INIT....is it true?? (i read that i do it calling "registerasyncpostbackcontrol", is it true??)

I write this code after the declaration of my dynamic ImageButton:
AsyncPostBackTrigger ImgAddTrigger = new AsyncPostBackTrigger();
ImgAddTrigger.ControlID = ImgAdd.ID + cont.ToString();
ImgAddTrigger.EventName = "Click";
UpdatePanelTabellaPartner.Triggers.Add(ImgAddTrigger);
UpdatePanelTabellaPartner.Update();

but it didn't work..so i think that i must call "registerasyncpostbackcontrol"

I'm Sorry for my english that is not good...
Thanks in advance for the answers!

If anybody solve this problem, i think that is the best!! I'm going crazy trying to solve this problem!!
Partecipa anche tu! Registrati!
Hai bisogno di aiuto ?
Perchè non ti registri subito?

Dopo esserti registrato potrai chiedere
aiuto sul nostro Forum oppure aiutare gli altri

Consulta le Stanze disponibili.

Registrati ora !
Copyright © dotNetHell.it 2002-2024
Running on Windows Server 2008 R2 Standard, SQL Server 2012 & ASP.NET 3.5