Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Stange problem with VS 2008

Options
  • 08-10-2009 1:00pm
    #1
    Registered Users Posts: 2,791 ✭✭✭


    Hi,

    I have a custom server control called TextDataCtrl.ascx that is working without any problems.

    On one page in my application, I use the following piece of code:
    else if (control is TextDataCtrl)
    {
         TextDataCtrl textDataCtrl = control as TextDataCtrl;
         if ((textDataCtrl != null)&&(!string.IsNullOrEmpty(value)))
         {
             textDataCtrl.LoadValuesFromTextDataXml(value);
         }
    }
    

    This code snippet is just after other constraints checking if the control is a Textbox, ListControl etc.

    My problem is that sometimes VS won't successfully build saying that TextDataCtrl doesn't exist. Sometimes Rebuilding all will solve the problem, but sometimes you might have to rebuild all a few times before the error messages will disappear. Sometimes the error messages won't go away at all, but clicking debug will successfully launch the application.

    This isn't a code problem as it works correctly when the application is built. Any suggestions how to get rid of this problem? It's annoying!


Comments

  • Registered Users Posts: 610 ✭✭✭nialo


    Are you building by page or the complete project? does it have dependancies on other projects that may have changed and not been rebuilt?


  • Registered Users Posts: 2,791 ✭✭✭John_Mc


    nialo wrote: »
    Are you building by page or the complete project? does it have dependancies on other projects that may have changed and not been rebuilt?

    Building the entire solution. Yes, there are dependencies, but these are included in the solution so a rebuild will build them also.


  • Registered Users Posts: 2,931 ✭✭✭Ginger


    Check your functions protection level and also the designer file. Sometimes they got out of sync and this causes this issue


Advertisement