1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Tpy6a [65]
3 years ago
10

Create a Sub called "daisyDecisions" that runs when you click a button. In this sub, you will create a program that determines w

hether he/she loves you, or loves you not. The program should receive, as an input, the number of petals on the flower (i.e., have a variable for petals) and then use that number to determine the output of the program: if the number of petals is even, then the program should output that he/she loves you not, if odd, then he/she loves you.

Computers and Technology
1 answer:
jenyasd209 [6]3 years ago
7 0

Answer:

see explaination

Explanation:

Please find the screenprint and the VBA code. As shown in the screenprint, range B1 is used to enter the number of petals. If you want to use a different cell for petals input, then change the code accordingly.

Also, the VBA code is placed in the Sheet1 module. No new modules are inserted.

Screenprint: see attachment for screenshot

VBA Code:

Private Sub CommandButton1_Click()

Call daisyDecisions

End Sub

Private Sub daisyDecisions()

Dim remainder As Integer

Dim noOfPetals As Integer

noOfPetals = Sheet1.Range("B1").Value

remainder = noOfPetals Mod 2

If remainder <> 0 Then

MsgBox "He/She loves you!!!"

Else

MsgBox "He/She loves you not!!!"

End If

End Sub

You might be interested in
Which file type is the best choice if the image will be made into a billboard?
matrenka [14]

Answer:

BMP

Explanation:

They are high resolution and are suitable for billboards.

6 0
1 year ago
To delete a database object, right-click the object in the Navigation Pane and then click ____ on the shortcut menu.
Reil [10]
Click DELETE on the Shortcut Menu. Be sure that the object you are deleting is closed before because it will not let you delete.
3 0
3 years ago
What is the ls option to list entries by lines instead of by columns?​
gogolik [260]

Sometimes I just meet some Unintelligen ppl

7 0
3 years ago
In order to be accredited by the Better Business Bureau, a business is required to publish a privacy notice on its website that
Svetradugi [14.3K]

Answer:

Explanation:Option D (Access)

7 0
3 years ago
Colleen has been missing a lot of work. She often calls in right as her shift is starting with some excuse about why she
yanalaym [24]
She is not showing honesty
5 0
2 years ago
Read 2 more answers
Other questions:
  • True or False?
    8·1 answer
  • Proper numeric keyboarding technique includes:
    15·1 answer
  • Which of the following are examples of how a company might use consumer data it had collected? a To decide what types of product
    10·1 answer
  • Write a program that asks for the names of three runners and the time, in minutes (no seconds, etc.), it took each of them to fi
    7·1 answer
  • Pseudocode is a good choice to communicate a____of a process
    10·1 answer
  • Me inculparon de crear una cuenta en Facebook y colocaron el barrio donde vivo, ¿cómo podría demostrar lo contrario? Ayuda urgen
    6·1 answer
  • Which line of code outputs the decimal portion of a float stored in the variable x? print (x % 1000) print (x) O print (x / 1000
    13·1 answer
  • What is computer specification
    15·1 answer
  • Where are 'if' and 'else' statements shown when printing a document in a word processor?
    8·1 answer
  • One of the most notable impacts of IT on business is improved
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!