Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
70
Calling Javascript from control inside a WARP
posted

Greetings,

I have a MasterPage with a WebDialogWindow and a ScriptManager.  The ScriptManager pulls in a JS file with WDW CSOM functions defined to show/hide the WDW.  On the MasterPage, I place regular HTML input buttons with onclick events wired to functions that call the WDW show/hide methods in the JS file and everything works as expected.

I have a ContentPage using the above MasterPage with a ScriptManagerProxy.  The Content page has its own HTML input buttons with onclick events wired to functions that call the WDW show/hide methods.  Clicking these HTML buttons show/hide the WDW on the Master page as expected.

Now, on the Content page I also have two ASP button controls (a "Hide" button and a "Show" button) inside a WARP.  Clicking "Hide" hides the hide button and shows the "Show" button and vice versa.  Since it is all in a WARP, only partial page updates are occuring as I expect.

Now, how do I envoke the JS methods to show/hide the WDW from the code behind wired up for each of these ASP buttons inside the WARP?  I would think something like:

ScriptManager.RegisterClientScriptBlock(.....)

But these envocations don't appear to ever fire.  Even something like this:

ScriptManager.RegisterClientScriptBlock(this, Page.GetType(), "script", "alert('hey dummy');", true);

Does not yeild an alert message when I click the button(s).

Any ideas on what to try next?

 

Thanks,

Ben