Jump to content

- Help Please (university Work) -


DanB

Recommended Posts

I have been working on javascript for 6 weeks now.I have to build an insurance comparison site by Thursday that will calculate the prices of 15companies. I will be happy to get one working first though!The company is called bb and they have a basic rate and discounts:Basic Price - 1231Discount for over 25's - 380Discount for female drivers - 89Discount for low mileage (less than 10.000 miles per annum) - 97Extra discount (If a driver is 25+, female and drives less than 10,000 PA) - 180No claims discount - 85 per year (maximum of 5 yrs)Hopefully, my code below will capture the user's data; I have then created variables, to then use this data and I have an array with the prices (that seems to work) too.My problem is with the functions and conditional statements that will add all these prices together, if all the conditions are satisfied on my form.The more I have looked at if/ else statements, the more I am confused and for days I have not been able to nail them - my head is spinning and the deadline is looming.Can anyone help finish?: if(age>=25)????If it was vb.net I would use 'Then' next to progress, but in javascript you seem to have to put an action next - when I want to carry on and say, '-380 then if the female drop down menu is chosen -89 etc.Please Help!Thanks Guys.d.My Code:<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>Insurance Comparison Site</title><link href="style.css" rel="stylesheet" type="text/css"/><script type="text/<javascript">var bbArray = new Array(6);bbArray[0] = 1231;bbArray[1] = 380;bbArray[2] = 89; bbArray[3] = 43; bbArray[4] = 180; bbArray[5] = 85; function CalculateSum(){ var calcForm=document.getElementByid("insForm"); var uName=calcForm.userName.value; var uAge = parseFloat(age); chosenOption=calcForm.gender.selectedindex; // you do not apear to need a variable for the radios; chosenOption=calcForm.ncd.selectedindex; // you just declare if(calcForm.mileage[1].checked==true) var bbsum=decimal // a try to get answer - form.Answer.value = bbArray[1] + bbArray[2];if(age>=25)bbArray[0] </script></head><body><p><br/><br/></p><h2><i>Would You Like an insurance quote?</i></h2><br/><form id="insForm"action=""><fieldset><legend>Please Enter Your Details</legend><br/><p><label for="name">Your Name: </label><input type="text" name="userName" id="userName" /><labe2 for="age">Your Age: </labe2><input type="integer" name="userAge" id="userAge" /></p> <p><labe3>Please Enter Your Gender</label> <select name="gender"> <option value="opt0"> </option> <option value="opt1">Male </option> <option value="opt2">Female </option></p> <br/><br/></select><p>Is Your Mileage Under 10, 000 Miles Per Year?<br/><input type="radio" name="mileage" value="Yes"/> Yes<br/><input type="radio" name="mileage" value="No"/> No<br/></p><p><label>How Much No Claims Bonus Do You Have?</label> <select name="ncd"> <option value="opt0"> </option> <option value="ncd0">0 Years </option> <option value="ncd1">One Year </option> <option value="ncd2">Two Years </option> <option value="ncd3">Three Years </option> <option value="ncd4">Four Years </option> <option value="ncd5">Five Years </option> </select> </p> <P><INPUT TYPE="button" VALUE="Calculate Prices" name="CalcButton" onClick="CalculateSum(variables I Think)"></P><P>Answer = <INPUT TYPE=TEXT NAME="Answer" SIZE=12></P></form></fieldset></body></html>

Link to comment
Share on other sites

Javascript, like C, Perl, and PHP, uses curly braces instead of THEN and ENDIF statements. This is true of most control structures, like functions, loops, and conditionals. So:

if (condition) {	// statements}

I'm not exactly sure if that is what you are asking.

Link to comment
Share on other sites

Your calculate function doesn't end correctly, you need the brackets there as well. This should get you started:

function CalculateSum(){  var calcForm=document.getElementByid("insForm");  var uName=calcForm.userName.value;  var uAge = parseFloat(age, 10);  chosenOption=calcForm.gender.selectedindex; // you do not apear to need a variable for the radios;   chosenOption=calcForm.ncd.selectedindex; // you just declare if(calcForm.mileage[1].checked==true)   var bbsum=bbArray[0]; // start with the base price  // a try to get answer - form.Answer.value = bbArray[1] + bbArray[2];  if(age>=25)  {	bbsum = bbsum - bbArray[1];  }}

Link to comment
Share on other sites

Guys - thanks!I did not think that there was anyone out there that was willing to help - I did not see the response so I carried on regardless trying to get one company called 'bb' insurance to work.I know I am close - but I still cannot get a price to quote!Can any one PLEASE get my buuton to work or link my JavaScript to the form PLEASE. I do not know what is wrong and I 've being trying for two weeks now and it's due in 4pm tomorrow - Arghhhhhhhh!Thank you.d. Here's what I have got now....<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>Insurance Comparison Site</title><link href="style.css" rel="stylesheet" type="text/css"/><script type="text/<javascript">var bbArray = new Array(6);bbArray[0] = 1231;bbArray[1] = 380;bbArray[2] = 89; bbArray[3] = 43; bbArray[4] = 180; bbArray[5] = 85; function calculateSum(){var insForm=document.getElementByid("insForm"); var uName=insForm.userName.value; var uAge = parseFloat(age, 10); chosenOption=insForm.gender.selectedindex; chosenOption=insForm.ncd.selectedindex; var price = bbArray[0]} if(age>=25){ bbArray[0] = (bbArray[0] - bbArray[1]) }else{ if (age<25) bbArray[0] = bbArray[0]} if(insForm.gender[0].selected){ bbArray[0] = (bbArray[0] - bbArray[2])}else{ if (insForm.gender[1].selected){ bbArray[0] = bbArray[0]} if(calcForm.mileage[1].checked==true)){ bbArray[0] = (bbArray[0] - bbArray[3])}else{ if (calcForm.mileage[1].checked==false){ bbArray[0] = bbArray[0]} if(age>=25 && insForm.gender[0].selected && calcForm.mileage[1].checked==true){ bbArray[0] = (bbArray[0] - bbArray[4]) } if(insForm.ncd[0].selected){ bbArray[0] = bbArray[0] }else{ if (insForm.ncd[1].selected){ bbArray[0] = (bbArray[0] - bbArray[5])}else{ if (insForm.ncd[2].selected){ bbArray[0] = bbArray[0] - (bbArray[5] * 2) }else{ if (insForm.ncd[3].selected){ bbArray[0] = bbArray[0] - (bbArray[5] * 3)}else{ if (insForm.ncd[4].selected){ bbArray[0] = bbArray[0] - (bbArray[5] * 4)}else{ if (insForm.ncd[5].selected){ bbArray[0] = bbArray[0] - (bbArray[5] * 5) } </script></head><body><p><br/><br/></p><h2><i>Would You Like an insurance quote?</i></h2><br/><form id="insForm"action=""><fieldset><legend>Please Enter Your Details</legend><br/><p><label for="name">Your Name: </label><input type="text" name="userName" id="userName" /><labe2 for="age">Your Age: </labe2><input type="integer" name="userAge" id="userAge" /></p> <p><labe3>Please Enter Your Gender</label> <select name="gender"> <option value="opt0"> </option> <option value="opt0">Male </option> <option value="opt1">Female </option></p> <br/><br/></select><p>Is Your Mileage Under 10, 000 Miles Per Year?<br/><input type="radio" name="mileage" value="Yes"/> Yes<br/><input type="radio" name="mileage" value="No"/> No<br/></p><p><label>How Much No Claims Bonus Do You Have?</label> <select name="ncd"> <option value="opt0"> </option> <option value="ncd0">0 Years </option> <option value="ncd1">One Year </option> <option value="ncd2">Two Years </option> <option value="ncd3">Three Years </option> <option value="ncd4">Four Years </option> <option value="ncd5">Five Years </option> </select></p><INPUT TYPE="button" VALUE="Calculate Prices" onClick=document.write"'Your Prices' + bbArray[0])"/P> </form></fieldset></body></html>

Link to comment
Share on other sites

First:var price = bbArray[0]}That bracket is in the wrong place. That's going to end the calculateSum function, but there's a lot of code after that that should go in the function also. Move that bracket to the end of the Javascript code.You should wire the button up like this:<INPUT TYPE="button" VALUE="Calculate Prices" onClick="calculateSum();">That will just execute the function when you hit the button. You should have a line at the end of the function that writes the result somewhere on the page instead of trying to do that inline in the onclick attribute. It will be better if you write the value to a textbox or div or something instead of using document.write. e.g.:<div id="feedback"></div><script type="text/javascript">document.getElementById("feedback").innerHTML += "some text";document.getElementById("feedback").innerHTML += "more text";document.getElementById("feedback").innerHTML += "more text";</script>

Link to comment
Share on other sites

Deirdre's Dad - I ReALLY appreciate this help.Please keep your cool with me, as I have only being doing JS 2 months (intensively for 2 weeks.)Now I can get it to show the words 'Price' and but no button. Actually the code for the button appears as text instead.I've been at this non stop for three days with only a few hours sleep. I will have to say I tried my best soon, even though I have got this far.As there were some unforeseen personal issues for me to sort last week that took two days long and as I have never asked for an extension, that might be my next course of action if I cannot get it going soon- I am so close, I know I am. <?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>Insurance Comparison Site</title><link href="style.css" rel="stylesheet" type="text/css"/><script type="text/<javascript">var bbArray = new Array(6);bbArray[0] = 1231;bbArray[1] = 380;bbArray[2] = 89; bbArray[3] = 43; bbArray[4] = 180; bbArray[5] = 85; function calculateSum(){var insForm=document.getElementByid("insForm"); var uName=insForm.userName.value; var uAge = parseFloat(age, 10); chosenOption=insForm.gender.selectedindex; chosenOption=insForm.ncd.selectedindex; var price = bbArray[0] if(age>=25){ bbArray[0] = (bbArray[0] - bbArray[1]) }else{ if (age<25) bbArray[0] = bbArray[0]} if(insForm.gender[0].selected){ bbArray[0] = (bbArray[0] - bbArray[2])}else{ if (insForm.gender[1].selected){ bbArray[0] = bbArray[0]} if(calcForm.mileage[1].checked==true)){ bbArray[0] = (bbArray[0] - bbArray[3])}else{ if (calcForm.mileage[1].checked==false){ bbArray[0] = bbArray[0]} if(age>=25 && insForm.gender[0].selected && calcForm.mileage[1].checked==true){ bbArray[0] = (bbArray[0] - bbArray[4]) } if(insForm.ncd[0].selected){ bbArray[0] = bbArray[0] }else{ if (insForm.ncd[1].selected){ bbArray[0] = (bbArray[0] - bbArray[5])}else{ if (insForm.ncd[2].selected){ bbArray[0] = bbArray[0] - (bbArray[5] * 2) }else{ if (insForm.ncd[3].selected){ bbArray[0] = bbArray[0] - (bbArray[5] * 3)}else{ if (insForm.ncd[4].selected){ bbArray[0] = bbArray[0] - (bbArray[5] * 4)}else{ if (insForm.ncd[5].selected){ bbArray[0] = bbArray[0] - (bbArray[5] * 5) } </script></head><body><p><br/><br/></p><h2><i>Would You Like an insurance quote?</i></h2><br/><form id="insForm"action=""><fieldset><legend>Please Enter Your Details</legend><br/><p><label for="name">Your Name: </label><input type="text" name="userName" id="userName" /><labe2 for="age">Your Age: </labe2><input type="integer" name="userAge" id="userAge" /></p> <p><labe3>Please Enter Your Gender</label> <select name="gender"> <option value="opt0"> </option> <option value="opt0">Male </option> <option value="opt1">Female </option></p> <br/><br/></select><p>Is Your Mileage Under 10, 000 Miles Per Year?<br/><input type="radio" name="mileage" value="Yes"/> Yes<br/><input type="radio" name="mileage" value="No"/> No<br/></p><p><label>How Much No Claims Bonus Do You Have?</label> <select name="ncd"> <option value="opt0"> </option> <option value="ncd0">0 Years </option> <option value="ncd1">One Year </option> <option value="ncd2">Two Years </option> <option value="ncd3">Three Years </option> <option value="ncd4">Four Years </option> <option value="ncd5">Five Years </option> </select></p><div id="Price"></div><script type="text/javascript">document.getElementById("Price").innerHTML += "Price";</script> <p>INPUT TYPE="button" VALUE="Calculate Prices" onClick="calculateSum();"</p></form></fieldset></body></html>

Link to comment
Share on other sites

The closing bracket around the function seems to have disappeared again.This part isn't making sense though:

  if(insForm.ncd[0].selected){	bbArray[0] = bbArray[0]  }else{  if (insForm.ncd[1].selected){	bbArray[0] = (bbArray[0] - bbArray[5])  }else{  if (insForm.ncd[2].selected){	bbArray[0] = bbArray[0] - (bbArray[5] * 2)  }else{  if (insForm.ncd[3].selected){	bbArray[0] = bbArray[0] - (bbArray[5] * 3)  }else{  if (insForm.ncd[4].selected){	bbArray[0] = bbArray[0] - (bbArray[5] * 4)  }else{  if (insForm.ncd[5].selected){	bbArray[0] = bbArray[0] - (bbArray[5] * 5)  }

Just count the brackets - there are 11 opening brackets and 6 closing brackets. There need to be the same amount. This part also has a different number of opening and closing brackets:

if(insForm.gender[0].selected){ bbArray[0] = (bbArray[0] - bbArray[2])}else{if (insForm.gender[1].selected){bbArray[0] = bbArray[0]}

Also, the button shows up as text because you seem to have changed it from a button to a paragraph:<p>INPUT TYPE="button" VALUE="Calculate Prices" onClick="calculateSum();"</p>

Link to comment
Share on other sites

The normal syntax for if-else-if is like this:

if (condition) {	// statements } else if (another condition) {	// statements } else if (yet another condition) {	// statements } else {	// default statements}

Link to comment
Share on other sites

Hi all - this got handed in today at 4 pm and 'no' I did not ask for extra time. I would like to see it all working even though I do have a mouth full of ulcers and I feel generally run down and should be in bed getting better.Deidre's Dad has been most kind - thanks!Now there's these 2 error messages:document.getElementById(uPrice) is null &calculateSum is not defined.Can anyone help me to learn please? Once and for all can I actually make it work? I am going around in circles trying loads of options that do not work. PLEASE!Thanks.d.

<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>Insurance Comparison Site</title><link href="style.css" rel="stylesheet" type="text/css"/><script type="text/<javascript">var bbArray = new Array(6);bbArray[0] = 1231;bbArray[1] = 380;bbArray[2] = 89; bbArray[3] = 43; bbArray[4] = 180; bbArray[5] = 85; function calculateSum(){var insForm=document.getElementByid("uForm");	var uName=insForm.userName.value;	var uAge = parseFloat(userAge);	chosenOption=insForm.uGender.selectedindex;				chosenOption=insForm.uNcd.selectedindex;		 	var uprice = bbArray[0]	}																if(uAge>=25){	bbArray[0] = (bbArray[0] - bbArray[1])				}else	if (uAge<25)	bbArray[0] = bbArray[0]}									if(insForm.uGender[0].selected){								bbArray[0] = (bbArray[0] - bbArray[2])}else	if (insForm.uGender[1].selected){	bbArray[0] = bbArray[0]}							if(calcForm.uMileage[1].checked==true)){						bbArray[0] = (bbArray[0] - bbArray[3])}else	if (calcForm.uMileage[1].checked==false){	bbArray[0] = bbArray[0]}													if(uAge>=25 && insForm.uGender[0].selected && calcForm.uMileage[1].checked==true){				bbArray[0] = (bbArray[0] - bbArray[4])	}	if(insForm.uNcd[0].selected){								bbArray[0] = bbArray[0] }else	if (insForm.uNcd[1].selected){	bbArray[0] = (bbArray[0] - bbArray[5])					}else	if (insForm.uNcd[2].selected){	bbArray[0] = bbArray[0] - (bbArray[5] * 2)					}else	if (insForm.uNcd[3].selected){	bbArray[0] = bbArray[0] - (bbArray[5] * 3)}else	if (insForm.uNcd[4].selected){	bbArray[0] = bbArray[0] - (bbArray[5] * 4)}else {	if (insForm.uNcd[5].selected){	bbArray[0] = bbArray[0] - (bbArray[5] * 5)							}</script>											</head><body><p><br/><br/></p><h2><i>Would You Like an insurance quote?</i></h2><br/><form id="insForm"action=""><fieldset><legend>Please Enter Your Details</legend><br/><p><label for="Name">Your Name: </label><input type="text" name="userName" id="userName" /><labe2 for="Age">Your Age: </labe2><input type="integer" name="userAge" id="userAge" /></p> <p><labe3>Please Enter Your Gender</label>       <select name="uGender">       <option value="opt0">         </option>         <option value="opt0">Male         </option>         <option value="opt1">Female         </option></p> <br/><br/></select><p>Is Your Mileage Under 10,000 Miles Per Year?<br/><input type="radio" name="mileage" value="Yes"/> Yes<br/><input type="radio" name="mileage" value="No"/> No<br/></p><p><label>How Much No Claims Bonus Do You Have?</label>       <select name="uNcd">       <option value="opt0">         </option>         <option value="ncd0">0 Years         </option>         <option value="ncd1">One Year         </option>         <option value="ncd2">Two Years         </option>         <option value="ncd3">Three Years         </option>         <option value="ncd4">Four Years         </option>         <option value="ncd5">Five Years         </option>         </select></p></script> <INPUT TYPE="button" VALUE="Calculate Prices" onClick="calculateSum();"><div id="feedback"></div><script type="text/javascript">document.getElementById("uPrice").innerHTML += "Your Price Is";</form></fieldset></body></html> 

Link to comment
Share on other sites

Here's a working version:

<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>Insurance Comparison Site</title><link href="style.css" rel="stylesheet" type="text/css"/><script type="text/javascript">var bbArray = new Array(6);bbArray[0] = 1231;bbArray[1] = 380;bbArray[2] = 89;bbArray[3] = 43;bbArray[4] = 180;bbArray[5] = 85;function calculateSum(){  var insForm=document.getElementById("insForm");  var uName= insForm.userName.value;  var uAge = parseFloat(insForm.userAge.value);  chosenOption=insForm.uGender.selectedindex;  chosenOption=insForm.uNcd.selectedindex;  var uprice = bbArray[0];  if(uAge>=25)  {    uprice = (uprice - bbArray[1]);  }  if(insForm.uGender[0].selected)  {    uprice = (uprice - bbArray[2]);  }  if(insForm.mileage[1].checked==true)  {    uprice = (uprice - bbArray[3]);  }  if(uAge>=25 && insForm.uGender[0].selected && insForm.mileage[1].checked==true)  {    uprice = (uprice - bbArray[4]);  }  if (insForm.uNcd[1].selected)  {    uprice = (uprice - bbArray[5]);  }  else if (insForm.uNcd[2].selected)  {    uprice = uprice - (bbArray[5] * 2);  }  else if (insForm.uNcd[3].selected)  {    uprice = uprice - (bbArray[5] * 3);  }  else if (insForm.uNcd[4].selected)  {    uprice = uprice - (bbArray[5] * 4);  }  else if (insForm.uNcd[5].selected)  {    uprice = uprice - (bbArray[5] * 5);  }  document.getElementById("feedback").innerHTML = "Your price: " + uprice;}</script></head><body><p><br/><br/></p><h2><i>Would You Like an insurance quote?</i></h2><br/><form id="insForm" action=""><fieldset><legend>Please Enter Your Details</legend><br/><p><label for="Name">Your Name: </label><input type="text" name="userName" id="userName" /><labe2 for="Age">Your Age: </labe2><input type="text" name="userAge" id="userAge" /></p><p><labe3>Please Enter Your Gender</label>       <select name="uGender">       <option value="opt0">         </option>         <option value="opt0">Male         </option>         <option value="opt1">Female         </option>        </select></p><br/><br/><p>Is Your Mileage Under 10,000 Miles Per Year?<br/><input type="radio" name="mileage" value="Yes"/> Yes<br/><input type="radio" name="mileage" value="No"/> No<br/></p><p><label>How Much No Claims Bonus Do You Have?</label>       <select name="uNcd">       <option value="opt0">         </option>         <option value="ncd0">0 Years         </option>         <option value="ncd1">One Year         </option>         <option value="ncd2">Two Years         </option>         <option value="ncd3">Three Years         </option>         <option value="ncd4">Four Years         </option>         <option value="ncd5">Five Years         </option>        </select></p><INPUT TYPE="button" VALUE="Calculate Prices" onClick="calculateSum();" /><div id="feedback"></div></form></fieldset></body>

This thing had quite a few errors left.This line has an extra bracket that doesn't belong:<script type="text/<javascript">In these lines:var insForm=document.getElementByid("uForm");var uName=insForm.userName.value;var uAge = parseFloat(userAge);The form had an ID of "insForm", not "uForm". The I in "getElementById" needs to be capitalized. There's no variable called userAge, that needed to be changed to the form element.You still had the bracket in the wrong place here:var uprice = bbArray[0]}That needs to go at the end of the function, not in the middle of it.For the rest of the code, where you have things like this:

if(uAge>=25){	bbArray[0] = (bbArray[0] - bbArray[1])				}else	if (uAge<25)	bbArray[0] = bbArray[0]}

You don't want to edit bbArray[0], that's the base price that doesn't change. You should be using the uprice variable instead. You don't want to change the base price for all insurance, you just want to calculate this one price. In the else statement, the line bbArray[0] = bbArray[0] doesn't do anything, setting a variable to itself has no effect. I just took those parts out.Later on in the code you use a variable name called calcForm, but the form element is insForm.Your if/else structure still had problems with brackets not lining up. I've simplified that, hopefully it makes more sense.In this line you should have a space between the ID and action:<form id="insForm"action="">For this line:<input type="integer" name="userAge" id="userAge" />There's no "integer" type, I changed that to text.The ending </select> tag for this dropdown is too far down:

<select name="uGender">	   <option value="opt0">		 </option>		 <option value="opt0">Male		 </option>		 <option value="opt1">Female		 </option></p> <br/><br/></select>

The br tags don't belong in a select list.For the radio buttons here:<input type="radio" name="mileage" value="Yes"/> Yes<br/>You gave them a name of "mileage" but the code was looking for "uMileage".The last script tag doesn't have an ending </script> tag, there's no element with an ID of uPrice, and that code doesn't really need to be there, so I just removed it.Look over the code above and ask if you have any questions.

Link to comment
Share on other sites

Just some guy - You are more than that mate.This was submitted yesterday. I am going to read your comments and understand exactly how it works and what I was doing wrong.This will hopefully be my future career. I got a B- for my HTML last term and thought I would do OK at JavaScript, After just handing in a VB.net project I wasted 2 nights on JS looking for a 'Then' statement to link my If/ else statements - forgetting that variabls can be dynamic.It was too late on that I understood functions are a bit like divs too (aren't they?.) I have tried to write it all as one statement with no seperate bits of code for outputs.By next week I have to revise for an SQL exam on Wednesday, do an assignment on the Russian economy by Thurday and have all my VB.net coursework in by Monday.I spent most of early evening yesterday trying to get this JS to work after submission, when I should have been on something else; I have to understand it as next year there is loads more on my course.Thank you so, so much - now I can look at what your comments and think, '???? Ahh so that what I was doing wrong' and 'I had not understood this or that.'I will get back to you over the next few days with comments on what I think I have learnt and understood from you if that is OK?Regards, d. :)

Link to comment
Share on other sites

It works - I cannot believe it!I know you helped me get there (granted and much appreciated) there is still a sense of satisfaction for me in knowing that I built most of it.Genuine rush - when it finally output a number! (wow man!)Anyway, when I get time i'll put all my comments back in and try and get some 'key stroke error code in there too' as well as adding my other 14 co's to work.I have been close I knew that but, with lots of variations - glad of your support.Regards, d. :)

Link to comment
Share on other sites

Simple one this time thanks to Just some guy.I noticed that gender [1] for female should have been selected in the if statements and not [0] (i think-who am I to say though) while I was trying to get all the 15 company prices to output.Still not there, but trying and I shouldn't be! Still, for some reason the female selection on my form is not changing the price and it should - I just cannot figure out why. Can anyone else? Everything looks fine to me?d.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...