Devstudio messing up resource.h
-
This has happened to me twice now, anyone know of an automated tool to fix the mess? When creating a dialog resource with a lot of controls, DevStudio seems to start assigning the controls new labels like IDC_BUTTON_69 and then in resource.h it's defining the labels to numbers which are already used for other labels (not used at the moment by the dialog). This means that when I finish adding buttons and try to define their labels to what I want, I can't use those identifiers that got reused! FFS! How difficult can it be for DevStudio to count up from the _APS_NEXT_CONTROL_VALUE number instead of doing this stupid thing. I imagine it THINKS it's doing me a favour... I really wish programs would stop trying to do me favours like this! :-) Now that I've got that off my chest, I suppose it would be pretty trivial to write my own program to fix the mess so I'll do that now. :) Thanks for listening, heh.
-
This has happened to me twice now, anyone know of an automated tool to fix the mess? When creating a dialog resource with a lot of controls, DevStudio seems to start assigning the controls new labels like IDC_BUTTON_69 and then in resource.h it's defining the labels to numbers which are already used for other labels (not used at the moment by the dialog). This means that when I finish adding buttons and try to define their labels to what I want, I can't use those identifiers that got reused! FFS! How difficult can it be for DevStudio to count up from the _APS_NEXT_CONTROL_VALUE number instead of doing this stupid thing. I imagine it THINKS it's doing me a favour... I really wish programs would stop trying to do me favours like this! :-) Now that I've got that off my chest, I suppose it would be pretty trivial to write my own program to fix the mess so I'll do that now. :) Thanks for listening, heh.
I'm not quite sure I understand your problem. I've never seen what you are describing. DevStudio always uses _APS_NEXT_CONTROL_VALUE when adding new controls. Are you instead, copying controls instead of adding new ones? How can you repeat the problem?
-
This has happened to me twice now, anyone know of an automated tool to fix the mess? When creating a dialog resource with a lot of controls, DevStudio seems to start assigning the controls new labels like IDC_BUTTON_69 and then in resource.h it's defining the labels to numbers which are already used for other labels (not used at the moment by the dialog). This means that when I finish adding buttons and try to define their labels to what I want, I can't use those identifiers that got reused! FFS! How difficult can it be for DevStudio to count up from the _APS_NEXT_CONTROL_VALUE number instead of doing this stupid thing. I imagine it THINKS it's doing me a favour... I really wish programs would stop trying to do me favours like this! :-) Now that I've got that off my chest, I suppose it would be pretty trivial to write my own program to fix the mess so I'll do that now. :) Thanks for listening, heh.
I'm not sure whether it will help you, but you might want to look at the shareware Programmer's Assistant from BarnStormer (http://www.barnstormer-software.com). It has several features for renumbering resources and it may be able to fix your problem
-
This has happened to me twice now, anyone know of an automated tool to fix the mess? When creating a dialog resource with a lot of controls, DevStudio seems to start assigning the controls new labels like IDC_BUTTON_69 and then in resource.h it's defining the labels to numbers which are already used for other labels (not used at the moment by the dialog). This means that when I finish adding buttons and try to define their labels to what I want, I can't use those identifiers that got reused! FFS! How difficult can it be for DevStudio to count up from the _APS_NEXT_CONTROL_VALUE number instead of doing this stupid thing. I imagine it THINKS it's doing me a favour... I really wish programs would stop trying to do me favours like this! :-) Now that I've got that off my chest, I suppose it would be pretty trivial to write my own program to fix the mess so I'll do that now. :) Thanks for listening, heh.
I'm in the process of developing an Add-In for Visual C++ 6.0 which addresses this. It includes a wizard to renumber resource symbols, and so may fit your needs - if so please let me know and I'll send you a copy. Visit http://www.resorg.co.uk for details. ================================================= Andy Metcalfe - Sonardyne International Ltd Email: andy.metcalfe@lineone.net Web: http://website.lineone.net/~andy.metcalfe ================================================= "I used to be a medieval re-enactor, but I'm alright now" =================================================
-
I'm in the process of developing an Add-In for Visual C++ 6.0 which addresses this. It includes a wizard to renumber resource symbols, and so may fit your needs - if so please let me know and I'll send you a copy. Visit http://www.resorg.co.uk for details. ================================================= Andy Metcalfe - Sonardyne International Ltd Email: andy.metcalfe@lineone.net Web: http://website.lineone.net/~andy.metcalfe ================================================= "I used to be a medieval re-enactor, but I'm alright now" =================================================
Andy, what you're working on looks brilliant! If you do want someone to help test it I'd love a copy as I'm sure this problem will come up again and I also like the idea of having the resources sorted alphabetically (obsessive? me?? :-)). Either way, good luck developing it and if I can help in any way let me know. From your webpage it looks like one of those projects that starts off looking simple but turns out to be quite complex if you want to do it right. (Unloading the project and all that.) Cheers, Le