Return-Path: X-Original-To: apmail-jmeter-user-archive@www.apache.org Delivered-To: apmail-jmeter-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id ADFCE7CD2 for ; Wed, 9 Nov 2011 16:52:12 +0000 (UTC) Received: (qmail 4708 invoked by uid 500); 9 Nov 2011 16:52:12 -0000 Delivered-To: apmail-jmeter-user-archive@jmeter.apache.org Received: (qmail 4684 invoked by uid 500); 9 Nov 2011 16:52:12 -0000 Mailing-List: contact user-help@jmeter.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "JMeter Users List" Delivered-To: mailing list user@jmeter.apache.org Received: (qmail 4670 invoked by uid 500); 9 Nov 2011 16:52:12 -0000 Delivered-To: apmail-jakarta-jmeter-user@jakarta.apache.org Received: (qmail 4667 invoked by uid 99); 9 Nov 2011 16:52:12 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 09 Nov 2011 16:52:12 +0000 X-ASF-Spam-Status: No, hits=2.1 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,SPF_NEUTRAL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: 216.139.236.26 is neither permitted nor denied by domain of stevesenior69@gmail.com) Received: from [216.139.236.26] (HELO sam.nabble.com) (216.139.236.26) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 09 Nov 2011 16:52:06 +0000 Received: from [192.168.236.26] (helo=sam.nabble.com) by sam.nabble.com with esmtp (Exim 4.72) (envelope-from ) id 1ROBNK-00007O-CP for jmeter-user@jakarta.apache.org; Wed, 09 Nov 2011 08:51:46 -0800 Date: Wed, 9 Nov 2011 08:51:46 -0800 (PST) From: ZK To: jmeter-user@jakarta.apache.org Message-ID: <1320857506378-4978325.post@n5.nabble.com> In-Reply-To: <1320856603874-4978279.post@n5.nabble.com> References: <1320849522828-4977855.post@n5.nabble.com> <1320856183695-4978250.post@n5.nabble.com> <1320856297741-4978259.post@n5.nabble.com> <1320856603874-4978279.post@n5.nabble.com> Subject: Re: Adding two numeric variables with decimal places MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit You probably noticed that doesn't work!!! We need to convert the total back to a string: double a= new Double((vars.get("adminfee"))); double b= new Double((vars.get("bbpfee"))); double x = (a+b); vars.put("feeTotal",Double.toString(x)); print(a); print(b); print(x); ZK -- View this message in context: http://jmeter.512774.n5.nabble.com/Adding-two-numeric-variables-with-decimal-places-tp4977855p4978325.html Sent from the JMeter - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org For additional commands, e-mail: user-help@jmeter.apache.org