Help with... weirdness opening designer

DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2

Thread: Help with... weirdness opening designer

  1. #1
    Join Date
    May 2005

    Unhappy Help with... weirdness opening designer

    Hi gang,

    Since this seems to be the only decent community on the Net that actually answers questions, and answers them lucidly, accurately and quickly... I have another challenge for y'all.

    Running VB.NET:
    I have a class, CIDUserControl, subclassed from System.Web.UI.UserControl. I recently rolled its functionality into another class I was working on called CID_WebUserControl, which exists in a completely separate solution/project. The CID_WebUserControl allows for the use of some custom controls I wrote.

    Here is the weirdness... I have a page, let's call it CIDInfo.ascx, which WAS subclassed from CIDUserControl, but then migrated beneath CID_WebUserControl. I had to do some bug fixing on the prior version (the current version is the migration to the new framework that includes CID_WebUserControl), and in order to do so, I needed to revert to the version of CIDInfo.ascx that subclassed CIDUserControl. This is where it gets interesting...

    If I try to open the designer on the old CIDInfo.ascx (subclassed from CIDUserControl), I get the following error in a dialog box:

    "The file could not be loaded into the Web Forms designer. Please correct the following error and then try loading it again:

    Type Abstract

    Make sure all of the classes used in the page are built or referenced in the project."

    Clicking the help button shows possible problems with a SRC attribute of the @Control directive. I do not have a SRC attribute so it isn't that. It also says something about problems with the Codebehind attribute where the referenced class is not available, which it is. Or:

    The class in the referenced file is inherited from a base class that is not referenced in the project. Normally, the class for your Web Forms page is inherited from the System.Web.UI.Page class, but if you are working with a user control or a Web Forms page for another platform, such as a mobile device, the base class might be different. CIDUserControl is part of the project I am working on.


    The class in the referenced file inherits from a base class in the project that has not been compiled. CIDUserControl is part of the project I am compiling, so that shouldn't be it.

    The last thing in the help is an issue with the Inherits attribute, but it is ignored if there is a Codebehind, so that shouldn't be it either.

    What is even weirder is if I change the superclass of CIDInfo.ascx to CID_WebUserControl everything works just fine, even though there is nothing in CIDInfo.ascx that references ANYTHING in CID_WebUserControl.

    I apologize for the innate difficulty in articulating this whole thing... I feel like I just told an entire story using nothing but pronouns.

    If anyone can shed some light on this, I would be GREATLY appreciative. Let me know if I can post any other info to help find a solution.



  2. #2
    Join Date
    May 2005
    I have had peculiar issues with user controls as well . I have come across this issue when if the user control codebehind is changed, mostly changes to event handlers and compiled i have seen errors similar to the ones u mentioned , not all the ones u mentioned, I remove the Register directive and then go to design, come back to HTML put the directive back and compile it seems fine, I know i havent answered ur question , but I am guessing this one of those many weirdos of the VS.Net environment

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
Latest Articles
Questions? Contact us.
Web Development
Latest Tips
Open Source

   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center