input values to accept 2 numbers & print the product,
difference and sum using switch case

Answer Posted / testengineer

a= Inputbox ("Enter the value of a :: ")
b= Inputbox ("Enter the value of b :: ")
S= int(a)+int(b)
D= int(a)-int(b)
P= int(a)*int(b)
Operation= Inputbox ("1.Sum"&vbnewline& "2.Difference" &vbnewline& "3.Product","Operators")

Select Case Operation
Case 1
Msgbox "Sum = "& S
Case 2
Msgbox "Difference = "& D
Case 3
Msgbox "Product = "& P
Case Else
Msgbox "Invalid Selection"

End Select

Is This Answer Correct ?    3 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which in-built functions are used to convert the specified expression in the form of date and string in the vbscript language?

546


What is the scope of a constant declared using public?

567


What is the purpose of on error resume next statement?

581


Explain the string concatenation function in vbscript?

544


How will you format a number in percetage format in vbscript?

593






Mention how you can call vbscript functions?

585


Which object provide information about a single runtime error in a vbscript?

607


What is loose binding? Why is it not a good practice to use it?

635


Illustrate briefly about the different types of statement

2027


Mention what is byref and byval parameters in vbscript?

579


Explain some uses of vb script?

556


How to take whole text output from screen of Bitmap Application.

1873


hi i am trying for testing job for 3+ experience(fake) can u suggest me what type of projects i can keep in my resume and how much of knoeledge i should have abt that project.thnks in advance.urgt plz

2588


How to write a VBscript for web page performance test i need a code send if any knows the code If any knows VBScript book plz send to me the link to my mail plz

2393


Mention what are the rules to name variable in vbscript?

540