While it is absolutely true what cosmo says about the relation between the tab order and the control ID in the .H file, I must disagree with him in suggesting to rely on it. A few years ago I made an application with several panels and several controls on the panels to customize dinamically. I relied on controls order with the mechanism described by Cosmo to build simple and elegant for loops to set attributes... After some months had to maintain the application and make some modifications: it was painful! Simply adding one control on a panel altered all the mechanism; besides it I had to note down on a paper initial and final control for each panel for limiting the for loop (on the panels there were indicators and decorations that didn't need customization), place a note on each panel to remember this particular mechanism...
I then moved to the array approach finding it more user friendly and safe.
Moreover, the possibility to create lists of controls and operate on all controls in the list with one command only simplified the code a lot: look into the toolbox and discover how powerful SetAttributeForList and similar commands are!
Message Edited by Roberto Bozzolo on 05-12-2005 11:12 PM