Home DotNet Telerik-The-Controls-collection-cannot-be-modified-because-the-control-contains-code-blocks
09.09.2010
Main Menu
Programming
.NET Controls
Operating System
Databases
Articles
Add to: Digg Add to: Del.icoi.us Add to: Reddit Add to: StumbleUpon Add to: Slashdot Add to: Yahoo Add to: Technorati Add to: Google
Telerik-The-Controls-collection-cannot-be-modified-because-the-control-contains-code-blocks

I have used the Telerik control on my aspx page. When I run the page I get the error message saying "The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>)".

One of thing you need to do is put your script code inside the RadCodeBlock.

<head id="Head1" runat="server"> 

    <telerik:RadCodeBlock runat="server" ID="radCodeBlock1"> 

        <script type="text/javascript"> 

            function pageLoad()

            {               

                // Get the combo box client id.

                cboIssueCategories = $find("<%= rcbCategory.ClientID %>");

            }

        </script> 

    </telerik:RadCodeBlock> 

</head>



Comments (2)
  • virux
    Thanks,, :evil: u saved my time. Am facing with telerik Q3
  • TD  - Thanks
    Hey, I found this article through Rick Strahl's post on this issue. Thank you, thank you, thank you!
Write comment
Your Contact Details:
Comment:
[b] [i] [u] [url] [quote] [code] [img]   
:D:angry::angry-red::evil::idea::love::x:no-comments::ooo::pirate::?::(
:sleep::););)):0
Security
Please input the anti-spam code that you can read in the image.

!joomlacomment 4.0 Copyright (C) 2009 Compojoom.com . All rights reserved."