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
4110
WebAsyncRefreshPanel Indicator Sample not working
posted

Hi All, I have used the sample documentation for changing the WARP indicator in javascript, but I get the following error message on my status bar: Can't eval WebRefreshPanel1_InitializePanel(oControl, ig_fireEvent.arguments[2], ig_fireEvent.arguments[3]); My code below is

directly from the infragistics sample.

Here is my javascript 

function

WebRefreshPanel1_Initialize(oPanel){

oPanel.getProgressIndicator().setImageUrl(

"~/images/loading.gif"

);

Here is my WARP control

<

igmisc:WebAsyncRefreshPanel ID="WebAsyncRefreshPanel1" runat="server" InitializePanel="WebRefreshPanel1_InitializePanel" Width="100%" ToolTip="just a tip" >

  • 4110
    posted

    Thanks Vince for the quick response!!! Sometimes you just need to sets of eyes on something. You guys are awesome.

  • 45049
    Verified Answer
    posted

    This error occurs because the name you've listed in the ASPX markup is "WebRefreshPanel1_InitializePanel" while the name of your function is "WebRefreshPanel_Initialize".  These must match.

    Additionally, in JavaScript, the tilde character "~" isn't recognized as a valid character in a URL path.  It's a special character used by ASP.NET on the server, which gets translated to an appropriate path on the server before being rendered to the browser.

    You should change the line of code where you call setImageUrl() to something like one of the following two lines, depending on where the image is in respect to your current page:

    oPanel.getProgressIndicator().setImageUrl("/MyApplicationVirtualDirectory/images/loading.gif");

    oPanel.getProgressIndicator().setImageUrl("./images/loading.gif");