SUBTOTAL Problem
SUBTOTAL Problem
(OP)
Dear All,
I will use the CAR table to illustrate my problem. Below is the code
TABLE FILE CAR
PRINT
COUNTRY
CAR
RETAIL_COST
DEALER_COST
BY COUNTRY NOPRINT
BY CAR NOPRINT SUBTOTAL DEALER_COST
END
-EXIT
However, when it is displayed on the webpage, the subtotal of the dealer cost is not in the same line as the subtotal.
What could be the problem? or how can i allign it so that it is in the same line?
Regards,
Yue-jeen
I will use the CAR table to illustrate my problem. Below is the code
TABLE FILE CAR
COUNTRY
CAR
RETAIL_COST
DEALER_COST
BY COUNTRY NOPRINT
BY CAR NOPRINT SUBTOTAL DEALER_COST
END
-EXIT
However, when it is displayed on the webpage, the subtotal of the dealer cost is not in the same line as the subtotal.
What could be the problem? or how can i allign it so that it is in the same line?
Regards,
Yue-jeen
RE: SUBTOTAL Problem
To solve this, use SUBFOOT instead. Through use of StyleSheet syntax, you can put the text for the '* TOTAL' anywhere you want.
Here's how I did what you asked:
CODE
PRINT
COUNTRY
CAR
RETAIL_COST
DEALER_COST
BY COUNTRY NOPRINT
BY CAR NOPRINT SUBFOOT
"TOTAL RETAIL COST<ST.RETAIL_COST"
ON TABLE SET STYLE *
TYPE=SUBFOOT, HEADALIGN=BODY,$
TYPE=SUBFOOT, LINE=1, ITEM=1, COLSPAN=2,$
TYPE=SUBFOOT, LINE=1, ITEM=2, JUSTIFY=RIGHT,$
ENDSTYLE
END
I replaced your SUBTOTAL with a SUBFOOT, with TWO parts: text and an imbedded field (the subtotal of RETAIL_COST).
Using the StyleSheet code, I said the first item (the text) should span two columns (COUNTRY and CAR), and the second item should be right justified.
RE: SUBTOTAL Problem
Thank you very much!!! That is exactly what I needed.
Regards,
YJ