title: Tic Tac Toe Using a GUI and Console in Visual Basic
body: <p>I am working on a program for my Visual Basic class and am supposed to create a game of Tic Tac Toe with two views a GUI view (which I know how to do) and a text view using the console which i have no idea what to do.</p>
  
  <p>I know this would use </p>
  
  <pre><code>Console.WriteLine()
  </code></pre>
  
  <p>But I've tried something like this:</p>
  
  <pre><code>  Module Module1
  
  Sub Main()
      Console.WriteLine("Welcome to Tic Tac Toe! Would you like to play a game?")
      Console.ReadKey(True)
  
      Console.WriteLine(" 1 | 2 | 3 ")
      Console.WriteLine("--- --- ---")
      Console.WriteLine(" 4 | 5 | 6 ")
      Console.WriteLine("--- --- ---")
      Console.WriteLine(" 7 | 8 | 9 ")
  End Sub
  
  End Module
  </code></pre>
  
  <p>But when I run the program, nothing happens. I'm sure this is a really stupid question (and is actually just one of many that I have for this program, but need to at least get the design worked out before I can start getting it to work in other areas) but we've never worked with the console before, everything we've done up until this point was all GUI based. </p>
  
  <p>Don't know that it helps any, but here is what I have in my module that holds the 2D array</p>
  
  <pre><code>Module Module1
  Const intMAX_ROWS As Integer = 2
  Const intMAX_COL As Integer = 2
  Public gameArray(intMAX_ROWS, intMAX_COL) As String
  
  Button1.Text = gameArray(0,0) 
  Button2.Text = gameArray(0,1)
  Button3.Text = gameArray(0,2)
  Button4.Text = gameArray(1,0)
  Button5.Text = gameArray(1,1)
  Button6.Text = gameArray(1,2)
  Button7.Text = gameArray(2,0)
  Button8.Text = gameArray(2,1)
  Button9.Text = gameArray(2,2)
  
  End Module
  </code></pre>
  
  <p>On the module, I'm getting errors located at each of the Button.Text lines that states </p>
  
  <pre><code>Declaration expected
  </code></pre>
  
  <p>Any help would be greatly appreciated. </p>