Formatting a drive with the operating running isn't possible. If you have the installation disk you boot from that and proceed to the installation point. Once you pressed the enter key to start the installation you will have the option to delete the current partition on the drive by first pressing the "L" key and then the "D" key on the next screen to confirm this.
Note this will wipe everything off of the drive at that time. Upon going to reinstall Windows look at the installation screen again and notice where it show the amount of drive space available. You simply answer yes to have the installer create and format a new partition.