//If example 5
Local CurrencyVar tax := 0;
Local CurrencyVar income := {Employee.Salary};
Local StringVar message := "";
If income < 8000 Then
(
message := "no";
tax := 0
)
Else If income >= 8000 And income < 20000 Then
(
message := "lowest";
tax := (income - 8000)*0.20
)
Else If income >= 20000 And income < 35000 Then
(
message := "middle";
tax := (20000 - 8000)*0.20 + (income - 20000)*0.29
)
Else
(
message := "highest";
tax := (20000 - 8000)*0.20 + (35000 - 20000)*0.29 +
(income - 35000)*0.40
);
//Use 2 decimal places and the comma as a
//thousands separator
Local StringVar taxStr := CStr (tax, 2, ",");
"You are in the " & message & " tax bracket. " &
"Your estimated tax is " & taxStr & "."
|
Business Objects,SAP 子公司 http://www.china.businessobjects.com/ 支持服务 http://www.china.businessobjects.com/support/ Web 上的产品文档 http://support.businessobjects.com/documentation/ |