Number Guessing game Help VBA

Status
Not open for further replies.

allisbad04

Duplicate Account
Joined
Nov 14, 2023
Messages
1
Office Version
  1. 365
Platform
  1. Windows
Hello, i am fairly new to vba and I have been trying to make a guessing game with these terms:
Have the computer randomly select a number between 1 and 100 using a “Reset”
button. Create a separate button “Guess” to prompt the user to guess the number. Let the player
know if their guess is too high or too low. If their guess is within two of the mystery number, do not
tell them if their guess was too high/low but output “Close but no cigar. Try again. Display the players guesses in column 1 and if it is too high or low in column 2.

I have been trying many different codes but I can not get it right can someone please show me how to code for this? thank you.
 

Excel Facts

Square and cube roots
The =SQRT(25) is a square root. For a cube root, use =125^(1/3). For a fourth root, use =625^(1/4).
Can you post what you do have? Which part isn't working?
 
Upvote 0
Duplicate to: VBA guessing game

In future, please do not post the same question multiple times. Per Forum Rules (#12), posts of a duplicate nature will be locked or deleted.

Also, as per rule 7, users are only allowed one account on this board, so I am locking this account.
 
Upvote 0
Status
Not open for further replies.

Forum statistics

Threads
1,223,911
Messages
6,175,327
Members
452,635
Latest member
laura12345

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top