Keypad tutorial.
Created by the Programming Ace.
www.UltimateGameProgramming.com


Description:

   The purpose of this tutorial is to create a keypad program.  In this
   program we will be creating the buttons and the edit box dynamically,
   meaning we won't be using the resource editor for this app.  We will
   dynamically create 12 buttons (1-9, 0, ., and C) and a edit box for
   output.  The only difficult part of this program is calculating the
   buttons position and the ids.  Everything is created in the constructor
   so thats where I want you to spend most of your attention.  Normally when
   you want to create buttons, listboxes, radiobuttons, or wherever during
   runtime, all you would need to do is create a object of CButton, CEdit,
   or whatever type of object you want and call the create function of that
   object and send in the neccessary information and thats it.  Since we are
   creating a keypad and many buttons all at once, we will be using a formula
   and a nested for loops in order to create the desired effect.  Lets look at
   the code.


Copyright September 2003
All Rights Reserved!
Allen Sherrod
ProgrammingAce@UltimateGameProgramming.com
www.UltimateGameProgramming.com