Need help with creating a caluclated pop up

S

smonczka

I have a list of software prices by licnes range, in other words 1-25
licenses would be 25$ 26-25 would be 20$. Users then have to multiply
the number of licenses they want in that range by the price on the
list. I can not create a wizard within the price sheet (insert
burocratic long story here). So what I would like to do is create a
pop up that would do the calculation for the users depending on what
cell they highlighted.

The user selects a price in the list. Click a button on the sheet and
a pop up allows them to do the calculation... say 1-25 licenses is
25$, they select the sell with 25$ in it. They click a button and a
form pops up with the 25$ in it and allows them to enter a multiplyer
to arrive at the total cost of the purchase.

I know how to make a pop up form and activate it with a macro button.
But I have no idea how i would automaticly bring in a selected cell
into the form and calculate it.

If anyone has some idea's please let me know. Thanks for the help!
 
L

Leith Ross

I have a list of software prices by licnes range, in other words 1-25
licenses would be 25$ 26-25 would be 20$. Users then have to multiply
the number of licenses they want in that range by the price on the
list. I can not create a wizard within the price sheet (insert
burocratic long story here). So what I would like to do is create a
pop up that would do the calculation for the users depending on what
cell they highlighted.

The user selects a price in the list. Click a button on the sheet and
a pop up allows them to do the calculation... say 1-25 licenses is
25$, they select the sell with 25$ in it. They click a button and a
form pops up with the 25$ in it and allows them to enter a multiplyer
to arrive at the total cost of the purchase.

I know how to make a pop up form and activate it with a macro button.
But I have no idea how i would automaticly bring in a selected cell
into the form and calculate it.

If anyone has some idea's please let me know. Thanks for the help!

Hello smonczka,

Here is a macro that will take the value of the selected cell and
multiply it by the value entered into the input box. There is no
validation or error checking in the code. You will need to add that
based on your needs.

Function CalcCost()

Dim Liceneses As Variant

Licenses = InputBox("Enter the number of licences you want to
purchase.")
CalcCost = Val(Licenses) * ActiveCell.Value

End Function

Sincerely,
Leith Ross
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top