CodeCharge Studio
search Register Login  

Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> PHP

 Editable Grid Texbox Calculation

Print topic Send  topic

Author Message
girish_327


Posts: 108
Posted: 10/18/2007, 7:58 AM

Hello ALL,
I saw your Post on CCS Forum. I thought you might be the one who could help me. I need to calculate some figures in Editable Grid on change. I used following code
But Its not working or giving me error

Error: unit_secondary_listElements is not defined
Source File: http://localhost/GWA_NEW/GWA/Add_Qty.php?unit_id=23
Line: 25


I like to calculate Each Row with following caluclations may be in OnLoad or OnChange Event

Please HELP me.

Thanks in Advance

<script language="JavaScript">
function StrToFloat(str)
{
if (str.indexOf(",") != -1) {
str = str.replace(",",".");
}
var result = parseFloat(str);
if (isNaN(result)) {
result = 0.0;
}
return result;
}

function Show_Total()
{

var TotalSum=0;
var Summ;
for(var i=0; i<unit_secondary_listElements.length;i++){
Summ = StrToFloat(unit_secondary_listElements[unit_secondary_listpriceID].value) *
StrToFloat(unit_secondary_listElements[unit_secondary_listquantityID].value);
}

}
</script>
_________________
Girish Baraskar
Web Designer/Developer
http://www.agnisdesigners.com
http://www.eindianpaintings.com
http://www.realestatekolhapur.com
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.