title: GUI Tipping Table from Console Based Application
body: <p><a href="http://i49.tinypic.com/sl43th.png" rel="nofollow">http://i49.tinypic.com/sl43th.png</a></p>
  
  <p>I recently wrote a console based application that a low tip rate, high tip rate, a  max dinner price, etc.. </p>
  
  <p>Now I am supposed to make it into a GUI and base it off of a user's input rather than predefined variables. The picture above is what the final result should look like. </p>
  
  <p>I don't understand how to go from console based to GUI. </p>
  
  <p>For helping reasons-
  The lowest tip rate textbox is labeled lTipRate
  The lowest dinner price textbox is labeled lDinBox
  The highest tip rate box is labeled hTipRate
  The highest dinner price is labeled hDinPRice
  The button is labeled calcTips</p>
  
  <p>Everything for the most part has been done through console based and not GUI throughout this semester so I am having a really hard time converting to and from.</p>
  
  <p>Could anyone explain how I would go about this?</p>
  
  <p>Thank you so much.</p>
  
  <p>Here is the code from the console based one. </p>
  
  <pre><code>    using System;
      public class TippingTable
      {
      public static void Main()
      {
      double dinnerPrice = 10.00;
      double tipRate;
      double tip;
  
      const double LOWRATE = 0.10;
      const double MAXRATE = 0.25;
      const double TIPSTEP = 0.05;
      const double MAXDINNER = 100.00;
      const double DINNERSTEP = 10.00;
  
      Console.Write("   Price");
      for(tipRate = LOWRATE; tipRate &lt;= MAXRATE;
          tipRate += TIPSTEP)
          Console.Write("{0,     8}" , tipRate.ToString("F"));
      Console.WriteLine();
      Console.WriteLine("----------------------------------------");
  
      tipRate = LOWRATE;
  
      while (dinnerPrice &lt;= MAXDINNER)
      {
          Console.Write("{0,     8}", dinnerPrice.ToString("C"));
          while (tipRate &lt;= MAXRATE)
          {
              tip = dinnerPrice * tipRate;
              Console.Write("{0,     8}",tip.ToString("F"));
              tipRate += 0.05;
          }
          dinnerPrice += DINNERSTEP;
          tipRate = LOWRATE;
          Console.WriteLine();
      }
  }
  </code></pre>
  
  <p>}</p>