Can't Change Control ID

Last post 12-19-2006 11:37 AM by mendoza. 6 replies.

Sort Posts:

  • Can't Change Control ID

    08-29-2006, 3:23 PM
    • Member
      168 point Member
    • mendoza
    • Member since 06-25-2002, 9:46 AM
    • Posts 37

    Working on an asp.net site using VS2005. When I'm in design view. I can't seem to change the ID of any control. When I change the ID, it immediately reverts back to the original value. If I go into source view, and change it there, it works. I can then go back to design view and see the new ID.

    Let me know if you've run into this problem and what, if any, is the fix. It's getting annoying.

     

    thanks for your help.

  • Re: Can't Change Control ID

    08-29-2006, 3:38 PM
    • All-Star
      17,710 point All-Star
    • vivek_iit
    • Member since 06-18-2006, 6:13 PM
    • New Delhi
    • Posts 3,171
    • TrustedFriends-MVPs

    Hi,

    I am suing VS 2005, ASP.NET 2.0 and C# and I am able to change ID of any control in the Design mode, and the changes persist.

    The IDs will not change while the application is running .

    Hope this helps,

    Vivek

     

     

  • Re: Can't Change Control ID

    08-29-2006, 4:07 PM
    • Member
      168 point Member
    • mendoza
    • Member since 06-25-2002, 9:46 AM
    • Posts 37

    ..and that's exactly the behavior I would like with my IDE as well.

    The app is not running. Also, the ID is the only property I can't edit in design mode. All other changes persist except for the ID. That's weird, and I'd hate to have to re-install VS just for that, but it may come to that point if I can't figure it out otherwise.

  • Re: Can't Change Control ID

    08-29-2006, 6:09 PM
    • Participant
      1,680 point Participant
    • samsp
    • Member since 08-08-2002, 5:35 PM
    • Posts 330
    • AspNetTeam
    When you change the name in design view, it attempts to do a refactor-rename that will fixup code that refers to that name. It sounds like this is failing so its rolling back the rename.
  • Re: Can't Change Control ID

    12-18-2006, 2:08 PM
    • Member
      112 point Member
    • gdzierzon
    • Member since 11-10-2006, 2:59 AM
    • Grantsville, UT
    • Posts 18
    I'm having the same issue. I can understand when there are existing contrls to refactor, but this happens right when a new control is added. Just try to rename it and it fails. Looked at the existing HTML and it's all properly nested and valid. Looks more like a bug in the IDE. Never had this problem in vs2003 or 2002
    Gregor Dzierzon
    MCSD, MCDBA, MCT
    www.learning2code.net

    Please remember to click “Mark as Answer” on the post that helps.
  • Re: Can't Change Control ID

    12-18-2006, 2:12 PM
    • Member
      112 point Member
    • gdzierzon
    • Member since 11-10-2006, 2:59 AM
    • Grantsville, UT
    • Posts 18

    see Rick Strahls blog about this issue - definitely a bug in vs 2005

    http://west-wind.com/weblog/posts/3192.aspx 

    Gregor Dzierzon
    MCSD, MCDBA, MCT
    www.learning2code.net

    Please remember to click “Mark as Answer” on the post that helps.
  • Re: Can't Change Control ID

    12-19-2006, 11:37 AM
    • Member
      168 point Member
    • mendoza
    • Member since 06-25-2002, 9:46 AM
    • Posts 37
    Thanks for pointing out that blog entry from Rick. Clearing the websitecache did the trick for me. See here: http://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=101992
Page 1 of 1 (7 items)