Write a macro that will ask for the number of gadgets needed and assign the valu
ID: 640391 • Letter: W
Question
Write a macro that will ask for the number of gadgets needed and assign the value to an integer variable. Then have the macro ask for the amount of raw material needed to make one gadget and assign this value to a single variable. Furthermore, add another box to ask for the amount of raw material available to manufacture gadgets and assign this number to a single variable. In your VBA code check that the number of gadgets needed per unit and the amount of raw material available are entered correctly (i.e., make sure that it is a number). If any one of the entries is not a number, print a message with an exclamation sign indicating that there was an error and terminate the macro. If the entries are numbers then calculate the number of gadgets that can be manufactured. If the number of gadgets that can be manufactured is greater than or equal to the number of gadgets needed, display a message indicating the number of gadgets that can be manufactured indicating the demand can be met. Otherwise display a message indicating that the raw material is not enough to manufacture the number of gadgets needed and inform the user the number of gadgets that can be manufactured with the available raw material.
Explanation / Answer
In $ A Particulars Old New Differential Income Annual Net Annual Net Annual Net Depricitaion (23,500) (235,000) (42,000) (420,000) (18,500) (185,000) Annual Variable Production Cost for 10 years (7,500) (75,000) (3,900) (39,000) 3,600 36,000 Proceeds from Old Machinery - - - 90,000 - 90,000 Differential (310,000) (369,000) (14,900) (59,000) B Sunk Cost $ Cost of New Equipment 420,000 Accumulated Depriciation 145,000 Total 565,000
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.