The first thing to do is to set up the form. Start up Visual Basic and create a new "Standard.exe" file. Select Form 1 and change the following properties as indicated:
Property |
Value |
(Name) |
frmSlider |
Caption | Slider |
Control Box | False |
BackColor | &H00FF0000& |
BorderStyle | 1-Fixed Single |
Height | 3330 |
Width | 3255 |
It should be pretty clear what each of these properties does. Your form should look like this:
Now, you need to add all the puzzle pieces. Set this up as an array of command buttons (if you forget how to do this, see the Tic Tac Toe tutorial, where we created an array of image controls). You can use your own properties for these, or you can use the following properties, which will give you something that looks just like my game.
Property |
Value |
(Name) |
cmdDisplayArray() |
Caption | 1, 2, 3, 4, 5, 6, 7, 8, 9 (depending on which position you're doing) |
Font | MS Sans Serif, Bold, Size 24 |
Height | 975 |
Index | 1, 2, 3, 4, 5, 6, 7, 8, 9 (depending on which position you're doing - should be the same as the caption) |
Width | 1095 |
After completing this step, your form should look something like this:
Now, you need to add the menus. They're pretty straight forward, so I'll just show you what they look like here...you can figure out how to add them using the menu editor.
That's it for the form! If you're ready to start the code, then click here or select Step 2: Setting Up on the navigation bar.