Im a writing a very simply program. My goal is to successfully use the evaluate function. I've been battling with one error for about 2 hours. Below is my code. All my errors come from the line where "when 1" is. If any one has any ideas on how i can fix this please let me know. thank you!
IDENTIFICATION DIVISION.
PROGRAM-ID. SALES-TAX.
DATE-WRITTEN. 11/5/10.
WORKING-STORAGE SECTION.
01 STATE PICTURE 99.
01 CT-TAX PICTURE V99 VALUE .06.
01 NY-TAX PICTURE V99999 VALUE .08875.
01 MA-TAX PICTURE V9999 VALUE .0625.
01 TAX PICTURE 99.
01 SALE PICTURE 999.
01 TOTAL PICTURE 999.
PROCEDURE DIVISION.
DISPLAY 'WHAT STATE WOULD YOU LIKE TO'.
DISPLAY 'CALCULATE THE SALES TAX FOR?'.
DISPLAY ' '.
DISPLAY '1.CT'.
DISPLAY '2.NY'.
DISPLAY '3.MA'.
DISPLAY ' '.
ACCEPT STATE.
DISPLAY ' '.
DISPLAY 'HOW MUCH IS YOUR SALE?'.
DISPLAY ' '
ACCEPT SALE.
DISPLAY ' '
EVALUATE STATE
WHEN 1
MULTIPLY CT-TAX BY SALE GIVING TAX.
ADD SALE TAX GIVING TOTAL.
DISPLAY 'TAX IS ' TAX ' AND TOTAL SALE IS ' TOTAL.
WHEN 2
MULTIPLY NY-TAX BY SALE GIVING TAX.
ADD SALE TAX GIVING TOTAL.
DISPLAY 'TAX IS ' TAX ' AND TOTAL SALE IS ' TOTAL.
WHEN 3
MULTIPLY MA-TAX BY SALE GIVING TAX.
ADD SALE TAX GIVING TOTAL.
DISPLAY 'TAX IS ' TAX ' AND TOTAL SALE IS ' TOTAL.
WHEN OTHER DISPLAY 'Data Entry Error'
END-EVALUATE
IDENTIFICATION DIVISION.
PROGRAM-ID. SALES-TAX.
DATE-WRITTEN. 11/5/10.
WORKING-STORAGE SECTION.
01 STATE PICTURE 99.
01 CT-TAX PICTURE V99 VALUE .06.
01 NY-TAX PICTURE V99999 VALUE .08875.
01 MA-TAX PICTURE V9999 VALUE .0625.
01 TAX PICTURE 99.
01 SALE PICTURE 999.
01 TOTAL PICTURE 999.
PROCEDURE DIVISION.
DISPLAY 'WHAT STATE WOULD YOU LIKE TO'.
DISPLAY 'CALCULATE THE SALES TAX FOR?'.
DISPLAY ' '.
DISPLAY '1.CT'.
DISPLAY '2.NY'.
DISPLAY '3.MA'.
DISPLAY ' '.
ACCEPT STATE.
DISPLAY ' '.
DISPLAY 'HOW MUCH IS YOUR SALE?'.
DISPLAY ' '
ACCEPT SALE.
DISPLAY ' '
EVALUATE STATE
WHEN 1
MULTIPLY CT-TAX BY SALE GIVING TAX.
ADD SALE TAX GIVING TOTAL.
DISPLAY 'TAX IS ' TAX ' AND TOTAL SALE IS ' TOTAL.
WHEN 2
MULTIPLY NY-TAX BY SALE GIVING TAX.
ADD SALE TAX GIVING TOTAL.
DISPLAY 'TAX IS ' TAX ' AND TOTAL SALE IS ' TOTAL.
WHEN 3
MULTIPLY MA-TAX BY SALE GIVING TAX.
ADD SALE TAX GIVING TOTAL.
DISPLAY 'TAX IS ' TAX ' AND TOTAL SALE IS ' TOTAL.
WHEN OTHER DISPLAY 'Data Entry Error'
END-EVALUATE