locked
Compiler error BC30002: Type MyGridView undefined caused by skin file RRS feed

  • Question

  • User-1887180874 posted

    Dear all,

    I am working on a web site converted to web application (vb, asp.net 4).

    In ~/Old_app_code there is a .vb class called MyGridView.

    I can use this custom control in my pages, putting at the start of the page the Register command.

    The big problem is when I want to use MyGridView in the skin file. The compilation goes fine, but as soon as I open the site (hosted on IIS 7) an error page is shown.

    The error reported is at line 136:

    Riga 134:        Private Shared __BuildControl__control57_skinKey As Object = System.Web.UI.PageTheme.CreateSkinKey(GetType(System.Web.UI.WebControls.GridView), "")
    Riga 135:        
    Riga 136:        Private Shared __BuildControl__control64_skinKey As Object = System.Web.UI.PageTheme.CreateSkinKey(GetType(OIM.CustomGridViewNameSpace.CustomGridView), "")
    Riga 137:        
    Riga 138:        <System.Diagnostics.DebuggerNonUserCodeAttribute()>  _

    Please note that this happens only when I put a MyGridView control in the skin. If I remove it, I can use the control in every other page.
    If I change anything in the Register tag, the error changes but it's clearer: unknown tag server MyGridView (that's why I am pretty sure the Register attributes are set fine.

    Unfortunately Google didn't help to fix it.

    Any help would be really appreciated.

    MT

    Wednesday, October 30, 2013 12:09 PM

Answers

  • User1071469379 posted

    Hi,

    I think this article can help you:

    http://mcsdeveloper.wordpress.com/2008/08/02/error-using-themes-to-skin-custom-controls-in-aspnet/

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, November 5, 2013 2:00 AM

All replies

  • User-1426144113 posted

    Hi,

    Could you share the project in the skydrive.

    Thanks

    Friday, November 1, 2013 3:37 AM
  • User1071469379 posted

    Hi,

    I think this article can help you:

    http://mcsdeveloper.wordpress.com/2008/08/02/error-using-themes-to-skin-custom-controls-in-aspnet/

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, November 5, 2013 2:00 AM
  • User-1887180874 posted

    I think this article can help you:

    http://mcsdeveloper.wordpress.com/2008/08/02/error-using-themes-to-skin-custom-controls-in-aspnet/

    Man, this fixes the problem, thank you!

    Tuesday, November 5, 2013 3:46 AM