steve fordon
Aug 6th, 2001, 11:20 AM
I have to design a game of battleships using control arrays. The main grid is a panel of command buttons 15 x 15= 225.
I have used the tag feature to attach a "grid reference" to each button within the array.
I need to be able to identify which button within the array was clicked, record the reference within an array of textboxes and limit the user to 5 different buttons at any time. For eg
if user presses cmd(34) then text(0)="34"
if user presses cmd(65)then text(1)="65" etc etc
When 5 buttons have been selected I can then send this info to a scoring procedure, wipe the counter and start counting with the next 5 clicks.
I have used the tag feature to attach a "grid reference" to each button within the array.
I need to be able to identify which button within the array was clicked, record the reference within an array of textboxes and limit the user to 5 different buttons at any time. For eg
if user presses cmd(34) then text(0)="34"
if user presses cmd(65)then text(1)="65" etc etc
When 5 buttons have been selected I can then send this info to a scoring procedure, wipe the counter and start counting with the next 5 clicks.