function ComputeTotal( form )
{
//Profit calculator 
//
Profit_rate1 = 1 + 0.00 // change the profit %
//                   ^^	
Profit_rate2 = 1 + 0.00 // change the profit %
//                   ^^	
Profit_rate3 = 1 + 0.00 // change the profit %
//                   ^^	
Profit_rate4 = 1 + 0.00 // change the profit %
//                   ^^	
Profit_rate5 = 1 + 0.00 // change the profit %
//                   ^^	
	CPU = form.CPU1.value = round(form.CPU.value * Profit_rate1)
	MAB = form.Mainboard1.value = round(form.Mainboard.value*Profit_rate2)
	MM1 = form.Memory2.value = round(form.Memory0.value * Profit_rate1)
	MM2 = form.Memory3.value = round(form.Memory1.value * Profit_rate1)
	HI1 = form.HDIDE2.value = round(form.HDIDE0.value * Profit_rate1)
	HI2 = form.HDIDE3.value = round(form.HDIDE1.value * Profit_rate1)
	HS1 = form.HDSCSI2.value = round(form.HDSCSI0.value * Profit_rate1)
	HS2 = form.HDSCSI3.value = round(form.HDSCSI1.value * Profit_rate1)
	VID = form.Video1.value = round(form.Video.value * Profit_rate3)
	MON = form.Monitor1.value = round(form.Monitor.value * Profit_rate1)
	CDR = form.CD1.value = round(form.CD.value * Profit_rate1)
	DVD = form.DVD1.value = round(form.DVD.value * Profit_rate4)
	RDR = form.Removable1.value = round(form.Removable.value * Profit_rate5)
	SND = form.Sound1.value = round(form.Sound.value * Profit_rate1)
	SPK = form.Speakers1.value = round(form.Speakers.value * Profit_rate1)
	MOD = form.Modem1.value = round(form.Modem.value * Profit_rate1)
	NET = form.Network1.value = round(form.Network.value * Profit_rate1)
	CAS = form.Case1.value = round(form.Case.value * Profit_rate1)
	MOS = form.Mouse1.value = round(form.Mouse.value * Profit_rate1)
	KEY = form.Keyboard1.value = round(form.Keyboard.value * Profit_rate1)

subtotal1 = CPU + MAB + MM1 + MM2 + HI1 + HI2 + HS1 + HS2 + VID 
	+ MON + CDR + DVD + RDR + SND + SPK + MOD + NET + CAS + MOS 
	+ KEY

form.subtotal1.value = subtotal1



}

function round(number,X) {
// rounds number to X decimal places, defaults to 2
X = (!X ? 2 : X);
return Math.round(number*Math.pow(10,X))/Math.pow(10,X);

}
