ANSWERS IN DETAIL AND WELL RESEARCHED ENSURING
100% ACCURACY
AIN3701
Data Analysis and automation
Assignment 2 (592338)
Due Date: 12th July 2024
Answers in detail and well researched
ensuring 100% accuracy
RESEARCHED!
ACCURATE !
ANSWERS!
20 YEARS
EXPERIENCE IS
THIS FIELD OF
STUDY!
NOT HAPPY?
100% MONEY BACK
GUARANTEED
AIN3701 | ASSIGNMENT 2 (592338) |12TH JULY 2024
ANSWERS IN DETAIL AND WELL RESEARCHED ENSURING 100% ACCURACY
, AIN3701 (Data Analysis and automation) Assignment 2 (592338) Due: 12th July 2024
AIN3701 (Data Analysis and automation)
Assignment 2 (592338)
Due Date: 12th July 2024
QUESTIONS COVERED:
SECTION A ................................................................................................................ 4
Required B: Discuss two benefits of making use of functions in VBA ........................ 6
Required C: benefits of automating this task to ikhishi likagogo ................................. 6
Required D: potential risk that may arise when coding the solution using VBA .......... 7
EXTRA ....................................................................................................................... 7
EXAMPLE: Required a:
Calculate the tax amount based on salary
If salary >=512801 And salary <=673000 Then
taxAmount= (salary – 512801)*0.36 + 115762
ElseIf salary > 673000 Then taxAmount = (salary-673000)*0.39+157800
Else
taxAmount=0
Answer:
1. Open the Excel file (Assignment_2.xlsx).
2. Perform the following VBA coding:
Function CalculateTax(salary As Double, age As Integer) As Double
Dim taxAmount As Double
Dim rebate As Double
' Calculate the tax amount based on salary
If salary >= 512801 And salary <= ………………………………………………….
EXAMPLE: Required b: Discuss Two Benefits of Using Functions in VBA
Answer:
Reusability:
Functions in VBA can be written once and then used multiple times throughout
………
1