ASP.NET Ajax Control toolkit – Common Problems

June 13, 2008

Problem 1 : This page is missing a HtmlHead control which is required for the CSS stylesheet link that is being added. Please add <head runat=”server” />

Solution :  make your HEAD tag  to <HEAD runat=”server”>

problem 2 : The Controls collection cannot be modified because the control contains code blocks (i.e. <% … %>).

Solution:  Looks like you are using <% tags in your HEAD section code like Javascript code etc…. To fix it wrap your head section with <div runat=”server”>  and </div>

Advertisements

7 Responses to “ASP.NET Ajax Control toolkit – Common Problems”

  1. Ashutosh Singhal Says:

    Good solution
    However if you dont want “Div” tag apearing in the source, then you could use the following

    put the value from code behind

    litHeader.Text = Common.getValues(“yourArg”)

  2. Ashutosh Singhal Says:

    Good solution
    However if you dont want “Div” tag apearing in the source, then you could use the following

    “asp:Literal id=”Litheader” runat=”server”

    put the value from code behind

    litHeader.Text = Common.getValues(”yourArg”)

    PS: somehow my markup is getting removed


  3. Solution : make your HEAD tag to

    Put this statement in master page that this page drived from.
    thanks

  4. Anuj Rohila Says:

    Thank You ajax problem is now solve

    Thank ‘s

  5. jeanphilt Says:

    Solution 2 worked for me :
    – In BasePage.aspx : removed runat=”server” from my head tag
    – In my Page.Master.aspx : I added before my and the closing tag after the tag

    No change done to all my Pages.aspx that inherits from BasePage.aspx

  6. jeanphilt Says:

    Sorry the tags got removed by wordpress, I meant :

    – In my Page.Master.aspx : I added a DIV as a parent of my HEAD, both with runat=”server

  7. Tuyen Nguyen Says:

    Thank you, works for me.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: