WebForm_InitCallback is not defined

This error eventually pops up, if you use the AjaxControlToolkit Rating Control. The Rating Control just doesn’t work, nothing happens when you click on it or hover over it. You find a couple of threads about it in Google but none of them helped me. I completly rewrote my web.config, removed all HttpModules, checked my Rewrite Logic for possible .axd lockups and nothing helped. That’s the exact error:

WebForm_InitCallback is not defined
Vote.aspx
Line 226

Line 226 says WebForm_InitCallback();Sys.Application.initialize();.

After wasting about 4 hours I checked out the CSS definitions which are being used by the Rating Control:

 StarCssClass="ratingStar"
                    WaitingStarCssClass="waitRatingStar"
                    FilledStarCssClass="filledRatingStar"
                    EmptyStarCssClass="emptyRatingStar"  

I checked the path to the images set in those 3 CSS definitions and noticed that waitRatingStar was pointing to an invalid path – a non existing image. After fixing that path the error was gone!

Like so many times a trivial fault can cost you lots of time – and the error which is being thrown by this fault unfortunately really doesn’t point you into the direction of a missing image. Hopefully this saves someone else searching time on this ;).

1 comment so far ↓

#1 Suresh on 07.26.08 at 8:12 am

WebForm_InitCallback is not defined:

I’m using Treeview Control in form,every thing working fine expanding,collapse and navigating pages when click on nodes,but firebug shows error:TreeView_SelectNode is not defined [Break on this error] HelpFile.aspx (line 1)

anyone can help me

Regards,

Suresh

Leave a Comment