FirstTimeVBA
New Member
- Joined
- Apr 23, 2020
- Messages
- 1
- Office Version
- 365
- 2019
- 2016
- Platform
- Windows
- MacOS
Hi all,
I'm trying to build a little game in excel:
Probably I will have bo build a more advanced macro, but I don't know where to start.
Anybody that can help me out ?
I'm trying to build a little game in excel:
- In sheet1:
- Four lists from columnA to columnD. Each lists contains different actions
- In sheet 2:
- Four buttons which randomly select on of the items to the corresponding list in sheet 1
- I would like to shown one text box that shows the most recent randomly selected items
- Ideally a item that has already been randomly selected cannot be selected again when the button is clicked again (this is a 'nice to have')
- In sheet 2 I have four cells (A1 to D1) with an INDEX function and RANDBETWEEN function to randomly select one of the items in the corresponding list
- I have created four buttons and assigned them to refresh the formula's in cell A1 to D1
- For my game I would actually only like to refresh the cell related to the button that has been clicked, or show a text field that only displays the item related to the button (other cells/lists can be refreshed in background but then there should be no function that remembers which items have already been randomly selected, otherwise I would miss them when clicking the corresponding button in a next round.
Probably I will have bo build a more advanced macro, but I don't know where to start.
Anybody that can help me out ?