2 Replies Latest reply on Aug 20, 2015 10:47 AM by jamie61880

    Calculations in form

    jamie61880 Level 1

      Hi. I am setting up a simple form that will do some calculations to determine the price of something that we are going to cut and sell. First, the user will choose a part number. Then they will type in the dimensions they want in the X_mm and Y_mm boxes. I have a formula in Excel that has other factors for determining the price for the part chosen. There is the cost of the item, the cutting cost we are charging and some other factor. The formula looks like this in Excel: =((E3/(ROUNDDOWN(50/B5, 0)*ROUNDDOWN(50/B6,0)))+E4)*E5

           I'm just wondering if I should do this calculation in Cold Fusion or SQL server management studio. We do not want the user to be able to see the formula either. Which way would be easier?

      Andy

        • 1. Re: Calculations in form
          mack_ Level 3

          I'm just wondering if I should do this calculation in Cold Fusion or

          SQL server management studio. We do not want the user to be able to

          see the formula either. Which way would be easier?

           

          If you don't want the user to see the formula you have to send the

          parameters to the server and calculate it there. I would use jQuery to

          catch change and keypress events and send the parameters via ajax to the

          server and display the response.

          • 2. Re: Calculations in form
            jamie61880 Level 1

            Thanks for the response. How do you send the parameters to the server and calculate everything there? I don't know how to use jQuery or ajax. Do you have an example I could look at?