Exchange

If Between Two Values in Android Studio

 

if(toKg < 1.0){
tTotalShippingCost.setText("Rs.500");
tSubTotalPrice.setText("Rs." + String.valueOf(sum + 500));
}else if(toKg >= 1.0 && toKg < 2.0) {
tTotalShippingCost.setText("Rs.650");
tSubTotalPrice.setText("Rs." + String.valueOf(sum + 650));
}else if(toKg >= 2.0 && toKg < 3.0) {
tTotalShippingCost.setText("Rs.750");
tSubTotalPrice.setText("Rs." + String.valueOf(sum + 750));
}



Post a Comment

0 Comments