Order Form template tutorial. Learn how to build a secure order form using logiforms.com. Includes instructions and a sample order form


Table of Contents
Introduction
Building the Customer Form
Building the Orders Form
Using Calculation Fields
Linking the forms via the AutoResponder
Creating the Tasks in logiBridge
Building Relationships in Microsoft Access
Summary
Creating a Relational Customer and Customer Orders System Using LogiBridge and MS Access
Page 4 of 8  


Using Calculation Fields

Next were going to add 3 calculation fields to the form. We'll add subTotal,shippingTotal and a OrderTotal field to the form. Calculation fields allow you to add conditional statements and calculate totals and subtotals based on selections on your form. For detailed information about how to write calculations, see this tech note.

Adding the SubTotal Calculation Field:
  1. Click the EDIT button next to the shipping field and select Insert Form Element > Insert After.
  2. Select Special Fields from the field type drop down menu and then select Calculation Field and press Continue.
  3. The Field Settings Window should now be loaded.
  4. Name the field SubTotal by entering it in the field name input
  5. Next, enter Sub Total in the caption input
  6. Click the Calculations Tab to advance.
  7. Cut and Paste the following into the calculation textarea

  8. 
    IF [PRODUCT] = 'Red Hat $12.95' THEN
    [SUBTOTAL] = 12.95
    ELSEIF [PRODUCT] = 'Purple Shirt $34.95' THEN
    [SUBTOTAL] = 34.95
    ELSEIF [PRODUCT] = 'Designed HandBag $165.95' THEN
    [SUBTOTAL] = 165.95
    ENDIF
    
    

  9. Click the Save & Close tab to save the new field and return to the form


Adding the Shipping Total Calculation Field:
  1. Click the EDIT button next to the subTotal field and select Insert Form Element > Insert After.
  2. Select Special Fields from the field type drop down menu and then select Calculation Field and press Continue.
  3. The Field Settings Window should now be loaded.
  4. Name the field shippingTotal by entering it in the field name input
  5. Next, enter Shipping Total in the caption input
  6. Click the Calculations Tab to advance.
  7. Cut and Paste the following into the calculation textarea

  8. 
    IF [SHIPPING] = 'Priority Courier $15.00' THEN
    [SHIPPINGTOTAL] = 15.00
    ELSEIF [SHIPPING] = 'Regular $0.00' THEN
    [SHIPPINGTOTAL] = 0.00
    ELSEIF [SHIPPING] = 'Overnight $25.00' THEN
    [SHIPPINGTOTAL] = 25.00
    ENDIF
    
    

  9. Click the Save & Close tab to save the new field and return to the form


Adding the Order Total Calculation Field:
  1. Click the EDIT button next to the shippingTotal field and select Insert Form Element > Insert After.
  2. Select Special Fields from the field type drop down menu and then select Calculation Field and press Continue.
  3. The Field Settings Window should now be loaded.
  4. Name the field orderTotal by entering it in the field name input
  5. Next, enter Total in the caption input
  6. Click the Calculations Tab to advance.
  7. Cut and Paste the following into the calculation textarea

  8. 
    [ORDERTOTAL] = [SUBTOTAL] + [SHIPPINGTOTAL]
    
    

  9. Click the Save & Close tab to save the new field and return to the form



  10. Now, when you change the shipping or the selected product, the subTotal, shippingTotal and the orderTotal are updated to reflect the selection.

    Figure 5: Your Form should now closely resemble the example shown here



Page 4 of 8  



Home | Form KB | Affiliates | Affiliate Login | Features and Functionality | Support | Privacy Policy | Terms of Use | Contact

Copyright 2008 logiforms