form field calculation problems

  • Thread starter Laura C. Bourgeois
  • Start date
L

Laura C. Bourgeois

I bought the WebsUnlimited Form Field calculator for Frontpage 2002 last week.

I need to be able to calculate not only items with possible quantities, but
also items with a quantity of 1 only in the same form. To accomplish this,
I had the following correspondence with Mike from WebsUnlimited on the
Microsoft FrontPage discussion group (I will describe the crux of my problem
beneath the following dialog):

Laura,

You have the calculation on the wrong field it should go on the check box.
Every field that is a part of the calculation will have
to have a calculation.

--
Mike -- FrontPage MVP '97-'02
J-Bots 2004 Released Special Pricing
http://www.websunlimited.com
FrontPage Add-ins Since '97 FP 2003 / 2002 / 2000 Compatible
message
Thank you, Mike! I tried it, and I hope I interpreted your directions
correctly, although apparently I have not. When I click "generate" in the
Form Field Calculator, I get this error: "frmGenericInsert: Insert
ScriptHead 13:Type Mismatch," but it seems to generate anyway.

After adding the code you describe (the total cost of this item is $185),
after I click the check box on the form, the subtotal field remains blank,
even after tabbing through it. Here is the code I ended up with:

<input type="checkbox" name="MEMBER_CONVENTION_REGISTRATION"
value="1">Convention Registration submitted by May 1, $185:
<input type="text" name="MEMBER_CONVENTION_REGISTRATION_BY_MAY1" size="7"
onclick="if (!this.checked) {this.value=0};
"Expression(this.form,'MEMBER_CONVENTION_REGISTRATION_BY_MAY1=MEMBER_CONVENTION_REGISTRATION*85+MEMBER_CONVENTION_REGISTRATION_BY_MAY1+100');"></b></font></p>

If you have any further diagnosis or suggestions, I would very much
appreciate it! Thanks so much! Laura

With Mike's kind assistance, I thought everything was fixed. The form was
working well when I tested it yesterday. We are testing it thoroughly before
actually putting it on our Website.

However, when staff members tried it today, many got varying bad results.
One staffer got a total of $8731 from sums actually totalling $331. Her
total for the MEMBER_CONVENTION_REGISTRATION checkbox registered $8585,
whereas mine for the same box registers $185, as it should. Another staffer
couldn't get the form to calculate subtotals at all, when tabbing or
clicking.

Why would results be so different on different computers? It is still
working fine on my machine, but apparently not on most others. I am going to
paste the calculation portion of the code for the form below. I would very
much appreciate any help you can give me. I am rather at my wit's end at
this point.

Thank you,
Laura C. Bourgeois

--------------------------------------------------------------------------------

<html>

<head>
<meta http-equiv="Content-Language" content="en-us">
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>2005 International Convention Orlando</title>
<script id="WU_Expression" type="text/javascript" >

// The following code is the property of Webs Unlimited, Inc.
http://www.websunlimited.com
// Copyright 2003
var token = '';var prog = '';var progIndex = 0;var oForm;var places = 2;var
prepend = 0;var DELIMITER = 1;var VARIABLE = 2;var NUMBER = 3;var TOKEN_SIZE
= 32;var TRUE = -1;var FALSE = 0;function
Expression(theForm,theExpression,Places,Prepend) {places = Places;prepend =
Prepend;progIndex = 0;prog = theExpression;oForm =
theForm;get_token();if(!token) {serror(2);}Level1();}function Level1(){var
slot;var ttok_type;var temp_token;var result = 0.0;if(tok_type == VARIABLE)
{temp_token = token;ttok_type = tok_type;if(typeof oForm[token] !=
"undefined" ) {slot = oForm[token];}else{serror(3);}get_token();if(token !=
'=') {putback();token = temp_token;tok_type =
ttok_type;}else{get_token();result = Level2();slot.value =
round(result,places);return;}}result=Level2();return result;}function
Level2(){var op = '';var hold = 0;var result = 0;result=Level3();while((op =
token) == '+' || op == '-') {get_token();hold=Level3();result =
arith(op,result, hold);}return result;}function Level3(){var op = '';var hold
= 0;var result = 0.0; result = Level4(); while((op = token) == '*' || op ==
'/') {get_token();hold = Level4();result = arith(op,result, hold);}return
result;}function Level4(){var hold = 0;var result = 0;result =
Level5();if((token) == '^') {get_token();hold = Level4();result =
arith('^',result, hold);}return result;}function Level5(){var op = '';var
result = 0.0;op = 0;if((tok_type==DELIMITER) && token == '+' || token == '-')
{op = token;get_token();}result = Level6();if(op)result =
unary(op,result);return result;}function Level6(){var result = 0.0;if((token
== '(') && (tok_type == DELIMITER)) {get_token();result = Level1();if(token
!= ')') { serror(1);} get_token(); } else { result = primitive(); }return
result;}function primitive(){var slot = 0;var result = 0.0;var sValue =
'';var i = 0;switch(tok_type) {case VARIABLE : if(typeof oForm[token] ==
"undefined") { result = 0.0; } else {switch (oForm[token].tagName) {case
'INPUT' : sValue = '0.0';if (oForm[token].type != 'checkbox' )sValue =
oForm[token].value; else if (oForm[token].checked) sValue =
oForm[token].value; while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i)
== '$') { ++i;}sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue)) {serror(4);}result = parseFloat(sValue); if
(isNaN(result)) result = 0; break;case 'SELECT' : sValue =
oForm[token].options[oForm[token].selectedIndex].value;
while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i) == '$') ++i;sValue =
sValue.substr(i,sValue.length-i); if (!isNumber(sValue)) serror(0);result =
parseFloat(sValue);if (isNaN(result)) result = 0; break;default:if(
oForm[token].length > 0 ) {for(i=0; i < oForm[token].length; i++)
{if(oForm[token].checked) {sValue =
oForm[token].value;while(sValue.charAt(i) == ' ') ++i;if(sValue.charAt(i)
== '$') ++i; sValue = sValue.substr(i,sValue.length-i);if (!isNumber(sValue))
serror(4);isNaN(parseFloat(sValue)) ? result += 0 : result +=
parseFloat(sValue); var sType = oForm[token].type.toLowerCase(); sType =
sType.toLowerCase();if (sType == 'radio') break;}}}break;}}get_token();return
result;case NUMBER:result = parseFloat(token);get_token();return
result;default:return result;}}
function arith(o,r,h){var t = 0.0;var ex = 0.0; switch(o) { case '-':r = r -
h; break;case '+': r = r + h; break;case '*': r = r * h;break;case '/':r = r
/ h;break;case '%':t = ((r) / (h));r = r - (t*(h));break;case '^':ex =
r;if(h==0) { r = 1.0;break;}for(t=h-1; t>0; --t) r = (r) * ex; break;}return
r;}function unary(o, r){if(o=='-') r = -(r);return r;}function putback(){var
t = '';t = token;for(;t;t++) progIndex--;}function find_var(s){var temp =
'';temp = oForm.s.value;if( temp == '' ) {return(0.0);}return
parseFloat(temp);}function serror(error){var e = new Array;e[0] = "Syntax
error";e[1] = "Unbalanced parentheses";e[2] = "no expression present";e[3]
= "Form field does not exist " + token;e[4] = "Not a number";alert(e[error]
+ ' - ' + token);}function get_token(){var temp = '';tok_type =
0;while(prog.charAt(progIndex) == ' ')
++progIndex;if(is_in(prog.charAt(progIndex), "+-*/%^=()")) {tok_type =
DELIMITER;temp += prog.charAt(progIndex++);} else
if(isAlpha(prog.charAt(progIndex)) || prog.charAt(progIndex) == '$') {
while(!isdelim(prog.charAt(progIndex))) temp +=
prog.charAt(progIndex++);tok_type = VARIABLE;} else if
(isDigit(prog.charAt(progIndex)) || prog.charAt(progIndex) == '.')
{while(!isdelim(prog.charAt(progIndex)))temp +=
prog.charAt(progIndex++);tok_type = NUMBER;}token = temp;}function
isdelim(c){if(is_in(c, "+-/*%^=() ") || c=='\t' || c=='\r')return 1; return
0;}function isAlpha(c) {var sAlpha =
'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';if (is_in(c,sAlpha))
return 1; else return 0;}function isDigit(c) {var Digits = '0123456789'; if
(is_in(c,Digits)) return 1; else return 0; }function isNumber(s) {var dec =
0;var i = 0;if(s.charAt(i) == '-' || s.charAt(i) == '+') ++i;for(i;
i<s.length; i++) { if(!isDigit(s.charAt(i))) {if (s.charAt(i) != '.' || dec )
return 0; else ++dec; }}return 1;}function is_in(ch,s){if(s.indexOf(ch) > -1)
return 1; else return 0;}function round(number,places) {number =
Math.round(number*Math.pow(10,places))/Math.pow(10,places);number += '';var x
= number.lastIndexOf('.'); if (x == -1 && places > 0) { number += '.'; x =
number.length -1; }for ( i = ((number.length-1) - x); i < places; i++) number
+= '0'; return prepend ? '$' + number : number;}
</script>
<script id="WU_Expression" type="text/javascript" >

// The following code is the property of Webs Unlimited, Inc.
http://www.websunlimited.com
// Copyright 2003
var token = '';var prog = '';var progIndex = 0;var oForm;var places = 2;var
prepend = 0;var DELIMITER = 1;var VARIABLE = 2;var NUMBER = 3;var TOKEN_SIZE
= 32;var TRUE = -1;var FALSE = 0;function
Expression(theForm,theExpression,Places,Prepend) {places = Places;prepend =
Prepend;progIndex = 0;prog = theExpression;oForm =
theForm;get_token();if(!token) {serror(2);}Level1();}function Level1(){var
slot;var ttok_type;var temp_token;var result = 0.0;if(tok_type == VARIABLE)
{temp_token = token;ttok_type = tok_type;if(typeof oForm[token] !=
"undefined" ) {slot = oForm[token];}else{serror(3);}get_token();if(token !=
'=') {putback();token = temp_token;tok_type =
ttok_type;}else{get_token();result = Level2();slot.value =
round(result,places);return;}}result=Level2();return result;}function
Level2(){var op = '';var hold = 0;var result = 0;result=Level3();while((op =
token) == '+' || op == '-') {get_token();hold=Level3();result =
arith(op,result, hold);}return result;}function Level3(){var op = '';var hold
= 0;var result = 0.0; result = Level4(); while((op = token) == '*' || op ==
'/') {get_token();hold = Level4();result = arith(op,result, hold);}return
result;}function Level4(){var hold = 0;var result = 0;result =
Level5();if((token) == '^') {get_token();hold = Level4();result =
arith('^',result, hold);}return result;}function Level5(){var op = '';var
result = 0.0;op = 0;if((tok_type==DELIMITER) && token == '+' || token == '-')
{op = token;get_token();}result = Level6();if(op)result =
unary(op,result);return result;}function Level6(){var result = 0.0;if((token
== '(') && (tok_type == DELIMITER)) {get_token();result = Level1();if(token
!= ')') { serror(1);} get_token(); } else { result = primitive(); }return
result;}function primitive(){var slot = 0;var result = 0.0;var sValue =
'';var i = 0;switch(tok_type) {case VARIABLE : if(typeof oForm[token] ==
"undefined") { result = 0.0; } else {switch (oForm[token].tagName) {case
'INPUT' : sValue = '0.0';if (oForm[token].type != 'checkbox' )sValue =
oForm[token].value; else if (oForm[token].checked) sValue =
oForm[token].value; while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i)
== '$') { ++i;}sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue)) {serror(4);}result = parseFloat(sValue); if
(isNaN(result)) result = 0; break;case 'SELECT' : sValue =
oForm[token].options[oForm[token].selectedIndex].value;
while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i) == '$') ++i;sValue =
sValue.substr(i,sValue.length-i); if (!isNumber(sValue)) serror(0);result =
parseFloat(sValue);if (isNaN(result)) result = 0; break;default:if(
oForm[token].length > 0 ) {for(i=0; i < oForm[token].length; i++)
{if(oForm[token].checked) {sValue =
oForm[token].value;while(sValue.charAt(i) == ' ') ++i;if(sValue.charAt(i)
== '$') ++i; sValue = sValue.substr(i,sValue.length-i);if (!isNumber(sValue))
serror(4);isNaN(parseFloat(sValue)) ? result += 0 : result +=
parseFloat(sValue); var sType = oForm[token].type.toLowerCase(); sType =
sType.toLowerCase();if (sType == 'radio') break;}}}break;}}get_token();return
result;case NUMBER:result = parseFloat(token);get_token();return
result;default:return result;}}
function arith(o,r,h){var t = 0.0;var ex = 0.0; switch(o) { case '-':r = r -
h; break;case '+': r = r + h; break;case '*': r = r * h;break;case '/':r = r
/ h;break;case '%':t = ((r) / (h));r = r - (t*(h));break;case '^':ex =
r;if(h==0) { r = 1.0;break;}for(t=h-1; t>0; --t) r = (r) * ex; break;}return
r;}function unary(o, r){if(o=='-') r = -(r);return r;}function putback(){var
t = '';t = token;for(;t;t++) progIndex--;}function find_var(s){var temp =
'';temp = oForm.s.value;if( temp == '' ) {return(0.0);}return
parseFloat(temp);}function serror(error){var e = new Array;e[0] = "Syntax
error";e[1] = "Unbalanced parentheses";e[2] = "no expression present";e[3]
= "Form field does not exist " + token;e[4] = "Not a number";alert(e[error]
+ ' - ' + token);}function get_token(){var temp = '';tok_type =
0;while(prog.charAt(progIndex) == ' ')
++progIndex;if(is_in(prog.charAt(progIndex), "+-*/%^=()")) {tok_type =
DELIMITER;temp += prog.charAt(progIndex++);} else
if(isAlpha(prog.charAt(progIndex)) || prog.charAt(progIndex) == '$') {
while(!isdelim(prog.charAt(progIndex))) temp +=
prog.charAt(progIndex++);tok_type = VARIABLE;} else if
(isDigit(prog.charAt(progIndex)) || prog.charAt(progIndex) == '.')
{while(!isdelim(prog.charAt(progIndex)))temp +=
prog.charAt(progIndex++);tok_type = NUMBER;}token = temp;}function
isdelim(c){if(is_in(c, "+-/*%^=() ") || c=='\t' || c=='\r')return 1; return
0;}function isAlpha(c) {var sAlpha =
'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';if (is_in(c,sAlpha))
return 1; else return 0;}function isDigit(c) {var Digits = '0123456789'; if
(is_in(c,Digits)) return 1; else return 0; }function isNumber(s) {var dec =
0;var i = 0;if(s.charAt(i) == '-' || s.charAt(i) == '+') ++i;for(i;
i<s.length; i++) { if(!isDigit(s.charAt(i))) {if (s.charAt(i) != '.' || dec )
return 0; else ++dec; }}return 1;}function is_in(ch,s){if(s.indexOf(ch) > -1)
return 1; else return 0;}function round(number,places) {number =
Math.round(number*Math.pow(10,places))/Math.pow(10,places);number += '';var x
= number.lastIndexOf('.'); if (x == -1 && places > 0) { number += '.'; x =
number.length -1; }for ( i = ((number.length-1) - x); i < places; i++) number
+= '0'; return prepend ? '$' + number : number;}
</script>
</head>

<body background="images/Webbkgnd.jpg">

<p>
<b><font face="CG Omega">
<img border="0" src="images/2003-2005logocolor.gif" width="250"
height="215"><br>
2005 International Convention<br>
Orlando, Florida</font></b></p>

<p>
<i><b><font face="CG Omega" color="#CC00FF">TAB to advance to the next field
and
calculate subtotals/totals</font></b></i></p>
<form method="POST" action="--WEBBOT-SELF--">
<!--webbot bot="SaveResults" u-file="../_private/form_results.htm"
s-format="HTML/BR" s-label-fields="TRUE" b-reverse-chronology="FALSE"
s-email-format="HTML/BR" b-email-label-fields="TRUE"
b-email-replyto-from-field="FALSE" s-email-replyto="2005 International
Convention Registration" b-email-subject-from-field="FALSE"
s-email-subject="2005 International Convention Registration" s-builtin-fields
s-email-address="(e-mail address removed)" startspan --><input
TYPE="hidden" NAME="VTI-GROUP" VALUE="0"><!--webbot bot="SaveResults" endspan
i-checksum="43374" --><hr>
<p><b><font face="CG Omega">1. MEMBER INFORMATION</font></b></p>
<p><font face="CG Omega"><b>Full name: <br>
<input type="text" name="REGISTRANT_Name" size="40"> </b></font> </p>
<p><font face="CG Omega"><b>5-Digit Member ID#:<input type="text"
name="REGISTRANT_ID" size="5"></b></font></p>
<p><font face="CG Omega"><b>State/Province/Nation & Chapter:<br>
<input type="text" name="REGISTRANT_SPN_Chapter" size="40"></b></font></p>
<p><font face="CG Omega"><b>Address:<br>
<input type="text" name="REGISTRANT_Street_Address"
size="50"></b></font></p>
<p><font face="CG Omega"><b>City, S/P/N, Zip/PC:<br>
<input type="text" name="REGISTRANT_City_SPN_Zip" size="20"></b></font></p>
<p><font face="CG Omega"><b>First name to appear on badge:<br>
<input type="text" name="REGISTRANT_BadgeName" size="20"></b></font></p>
<p><font face="CG Omega"><b>Daytime Phone:<br>
<input type="text" name="REGISTRANT_phone" size="30"></b></font></p>
<p><font face="CG Omega"><b>E-mail Address:<br>
<input type="text" name="REGISTRANT_email" size="40"></b></font></p>
<p><font face="CG Omega"><b>I am actively employed/engaged in education:<br>
<input type="radio" value="Yes" name="REGISTRANT_EEinEducation">Yes
<input type="radio" name="REGISTRANT_EEinEducation"
value="No">No</b></font></p>
<hr>
<p><b><font face="CG Omega">2. EMERGENCY CONTACT (NOT Attending
Convention)</font></b></p>
<p><font face="CG Omega"><b>Name: <input type="text"
name="EMERGENCY_CONTACT_Name" size="40"></b></font></p>
<p><font face="CG Omega"><b>Phone: <input type="text"
name="EMERGENCY_CONTACT_phone" size="30"></b></font></p>
<hr>
<p><b><font face="CG Omega">3. CONVENTION REGISTRATION</font></b></p>
<p><b><font face="CG Omega">Pre-registration Policy: To be considered
pre-registered, your
registration must be received by Friday, June 17. After this date, all
registrations and changes must be processed at the Convention Registration
Desk during the Convention.</font></b></p>
<blockquote>
<p><b><font face="CG Omega">A. Member Registration (Includes EDUCATIONAL
SYMPOSIUM, Name Badge,
Convention Registration Packet, Business Sessions, Speakers, Regional
Luncheon
and Reception, Banquet and Favor.)</font></b></p>
<p><font face="CG Omega"><b>Banquet Choice:<br>
<input type="radio" name="REGISTRANT_BanquetChoice" value="Beef">Beef
<input type="radio" name="REGISTRANT_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="REGISTRANT_BanquetChoice"
value="Vegetarian">Vegetarian</b></font></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>TOTAL<br>
<input type="checkbox" name="MEMBER_CONVENTION_REGISTRATION" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'MEMBER_CONVENTION_REGISTRATION=MEMBER_CONVENTION_REGISTRATION*100+85',2,0);">Convention Registration submitted by May 1:
$185 </b></font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">B. Educational Symposium ONLY —
Wednesday, July 6</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>TOTAL<br>
<input type="checkbox" name="EDUCATIONAL_SYMPOSIUM_REGISTRATION" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'EDUCATIONAL_SYMPOSIUM_REGISTRATION=EDUCATIONAL_SYMPOSIUM_REGISTRATION*45+40',2,0);">Educational
Symposium Registration submitted by May 1:
$85</b></font></p>
<blockquote>
<blockquote>
<p><b><font face="CG Omega">Professional Growth/Fraternity Education
Breakout Session Choices</font></b></p>
<ul>
<li><b><font face="CG Omega"><a target="_blank"
href="Breakout.htm">Click here for session titles
and descriptions.</a></font></b></li>
</ul>
<p><font face="CG Omega"><b>Fill in session numbers, indicating your
first, second and third choices
for each July 6 time slot.<br>
July 6; 11:15 AM-12:15 PM<br>
(Sessions 1-19):<br>
First Choice #<input type="text" name="ES_FIRST_MORNING_SESSION_CHOICE"
size="2">
<br>
Second Choice#<input type="text" name="ES_SECOND_MORNING_SESSION_CHOICE"
size="2">
<br>
Third Choice#<input type="text" name="ES_THIRD_MORNING_SESSION_CHOICE"
size="2"><br>
July 6; 2:45-3:45 PM<br>
(Sessions 20-38):<br>
First Choice #<input type="text" name="ES_FIRST_AFTERNOON_SESSION_CHOICE"
size="2">
<br>
Second Choice#<input type="text" name="ES_SECOND_AFTERNOON_SESSION_CHOICE"
size="2">
<br>
Third Choice#<input type="text" name="ES_THIRD_AFTERNOON_SESSION_CHOICE"
size="2"></b></font></p>
</blockquote>
</blockquote>
<p align="right"><font face="CG Omega"><b>SESSION 39, Tuesday, July 5,
includes transportation,
<input type="text" name="QTY_SESSION_39" size="2"> at $20
each:
<input type="text" name="SESSION_39_TOTAL" size="7"
onblur="Expression(this.form,'SESSION_39_TOTAL=QTY_SESSION_39*20',2,1);"><br>
SESSION 40, Monday, July 11, includes transportation,
<input type="text" name="QTY_SESSION_40" size="2"> at $20 each:
<input type="text" name="SESSION_40_TOTAL" size="7"
onblur="Expression(this.form,'SESSION_40_TOTAL=QTY_SESSION_40*20',2,1);"></b></font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">C. Optional Special Function
Fees:</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>
<input type="checkbox" name="PAST_SPN_PRESIDENTS_LUNCHEON" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'PAST_SPN_PRESIDENTS_LUNCHEON=PAST_SPN_PRESIDENTS_LUNCHEON*20+5',2,0);">Past S/P/N Presidents' Luncheon (Past S/P/N Presidents only):
$25<br>
<input type="checkbox" name="LITTLE_WIGS_BREAKFAST" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'LITTLE_WIGS_BREAKFAST=LITTLE_WIGS_BREAKFAST*10+10',2,0);">Little
Wigs Breakfast (Past International Chapter Members): $20</b></font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">D. NONMEMBER GUEST TICKETS<br>
Please specify how many tickets you are purchasing for each
event.</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>Banquet Guest(s) (Not included in
Alpha Delta Kappa Association Registration Fee),
<input type="text" name="QTY_BANQUET_GUEST" size="2"> at $55 each:
<input type="text" name="BANQUET_GUEST_TOTAL" size="7"
onblur="Expression(this.form,'BANQUET_GUEST_TOTAL=QTY_BANQUET_GUEST*55',2,1);"></b></font></p>
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<p align="left"><font face="CG Omega"><b>Banquet Choice:<br>
<input type="radio" name="GUEST1_BanquetChoice" value="Beef">Beef
<input type="radio" name="GUEST1_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="GUEST1_BanquetChoice"
value="Vegetarian">Vegetarian<br>
<input type="radio" name="GUEST2_BanquetChoice" value="Beef">Beef
<input type="radio" name="GUEST2_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="GUEST2_BanquetChoice"
value="Vegetarian">Vegetarian</b></font></p>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
<p align="right">
<font face="CG Omega"><b>
Regional
Luncheon Guest(s),
<input type="text" name="QTY_REGIONAL_LUNCHEON_GUESTS" size="2"> at $30
each:
<input type="text" name="REGIONAL_LUNCHEON_GUEST_TOTAL" size="7"
onblur="Expression(this.form,'REGIONAL_LUNCHEON_GUEST_TOTAL=QTY_REGIONAL_LUNCHEON_GUESTS*30',2,1);"></b></font></p>
<p align="right"><b><font face="CG Omega">E. ALPHA DELTA KAPPA ASSOC. FOR
MEN CONVENTION
REGISTRATION(S)</font></b><font face="CG Omega"><b> <input
type="text" name="QTY_ADKA_REGISTRATIONS" size="2">
at $40 each:
<input type="text" name="ADKA_REGISTRATION_TOTAL" size="7"
onblur="Expression(this.form,'ADKA_REGISTRATION_TOTAL=QTY_ADKA_REGISTRATIONS*40',2,1);"></b></font><b><font face="CG Omega"><br>
(Includes Annual Dues, Alpha Delta Kappa Association Breakfast, Reception
and
General Session Speakers. Does not include Banquet. Alpha Delta
Kappa Association tickets may be purchased above for the Banquet and/or the
Regional Luncheon.)</font></b></p>
<blockquote>
<blockquote>
<p align="left"><font face="CG Omega"><b>Name to appear on badge:
<input type="text" name="ADKA_BADGE_NAME" size="40"><br>
</b></font></p>
</blockquote>
</blockquote>
<p align="right"><font face="CG Omega"><b>Alpha Delta Kappa Association
Membership Dues for Alpha Delta Kappa Association members <br>
NOT ATTENDING CONVENTION, <input type="text" name="QTY_ADKA_DUES"
size="2"> at $6
each:
<input type="text" name="ADKA_DUES_TOTAL" size="3"
onblur="Expression(this.form,'ADKA_DUES_TOTAL=QTY_ADKA_DUES*6',2,1);"></b></font></p>
<blockquote>
<p align="right"><font face="CG Omega"><b>Alpha Delta Kappa Association
member name:<br>
<input type="text" name="ADKA_MEMBER_NAME" size="40"></b></font></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>F. 2005 International Convention
charm and/or pin: charm(s),
<input type="text" name="QTY_CHARMS" size="2"> at $5 each:
<input type="text" name="CHARM_TOTAL" size="7"
onblur="Expression(this.form,'CHARM_TOTAL=QTY_CHARMS*5',2,1);"><br>
pin(s), <input type="text" name="QTY_PINS" size="2"> at $5 each:
<input type="text" name="PIN_TOTAL" size="7"
onblur="Expression(this.form,'PIN_TOTAL=QTY_PINS*5',2,1);"></b></font></p>
<p align="right"><font face="CG Omega"><b>TOTAL FEE in U.S. FUNDS: (Add
registration, special
functions, guests' tickets and pin/charm)
<input type="text" name="TOTAL_FEE_TO_BE_CHARGED" size="7"
onblur="Expression(this.form,'TOTAL_FEE_TO_BE_CHARGED=MEMBER_CONVENTION_REGISTRATION+EDUCATIONAL_SYMPOSIUM_REGISTRATION+SESSION_39_TOTAL+SESSION_40_TOTAL+PAST_SPN_PRESIDENTS_LUNCHEON+LITTLE_WIGS_BREAKFAST+BANQUET_GUEST_TOTAL+REGIONAL_LUNCHEON_GUEST_TOTAL+ADKA_REGISTRATION_TOTAL+ADKA_DUES_TOTAL+CHARM_TOTAL+PIN_TOTAL',2,1);"></b></font></p>
<p align="left"><b><font face="CG Omega">CANCELLATION POLICY:
Cancellations must be received in writing
by June 17, 2005 to qualify for a refund.</font></b></p>
 
J

Jon Spivey

Hi Laura,
You really should address this issue with Mike himself - he's a competent
programmer who's sold you a product so he should support it. If you can't
get a sensible response from him ditch the product then post back and we'll
help you out - but we (or at least I - as "probably" the most knowledgable
javascript guy in the group) draw the line at fixing code sold to you by
someone else.

--
Cheers,
Jon
Microsoft MVP

.. "Laura C. Bourgeois said:
I bought the WebsUnlimited Form Field calculator for Frontpage 2002 last
week.

I need to be able to calculate not only items with possible quantities,
but
also items with a quantity of 1 only in the same form. To accomplish
this,
I had the following correspondence with Mike from WebsUnlimited on the
Microsoft FrontPage discussion group (I will describe the crux of my
problem
beneath the following dialog):

Laura,

You have the calculation on the wrong field it should go on the check box.
Every field that is a part of the calculation will have
to have a calculation.

--
Mike -- FrontPage MVP '97-'02
J-Bots 2004 Released Special Pricing
http://www.websunlimited.com
FrontPage Add-ins Since '97 FP 2003 / 2002 / 2000 Compatible
message
Thank you, Mike! I tried it, and I hope I interpreted your directions
correctly, although apparently I have not. When I click "generate" in
the
Form Field Calculator, I get this error: "frmGenericInsert: Insert
ScriptHead 13:Type Mismatch," but it seems to generate anyway.

After adding the code you describe (the total cost of this item is $185),
after I click the check box on the form, the subtotal field remains
blank,
even after tabbing through it. Here is the code I ended up with:

<input type="checkbox" name="MEMBER_CONVENTION_REGISTRATION"
value="1">Convention Registration submitted by May 1, $185:
<input type="text" name="MEMBER_CONVENTION_REGISTRATION_BY_MAY1"
size="7"
onclick="if (!this.checked) {this.value=0};
"Expression(this.form,'MEMBER_CONVENTION_REGISTRATION_BY_MAY1=MEMBER_CONVENTION_REGISTRATION*85+MEMBER_CONVENTION_REGISTRATION_BY_MAY1+100');"></b></font></p>

If you have any further diagnosis or suggestions, I would very much
appreciate it! Thanks so much! Laura

With Mike's kind assistance, I thought everything was fixed. The form was
working well when I tested it yesterday. We are testing it thoroughly
before
actually putting it on our Website.

However, when staff members tried it today, many got varying bad results.
One staffer got a total of $8731 from sums actually totalling $331. Her
total for the MEMBER_CONVENTION_REGISTRATION checkbox registered $8585,
whereas mine for the same box registers $185, as it should. Another
staffer
couldn't get the form to calculate subtotals at all, when tabbing or
clicking.

Why would results be so different on different computers? It is still
working fine on my machine, but apparently not on most others. I am going
to
paste the calculation portion of the code for the form below. I would
very
much appreciate any help you can give me. I am rather at my wit's end at
this point.

Thank you,
Laura C. Bourgeois

--------------------------------------------------------------------------------

<html>

<head>
<meta http-equiv="Content-Language" content="en-us">
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>2005 International Convention Orlando</title>
<script id="WU_Expression" type="text/javascript" >

// The following code is the property of Webs Unlimited, Inc.
http://www.websunlimited.com
// Copyright 2003
var token = '';var prog = '';var progIndex = 0;var oForm;var places =
2;var
prepend = 0;var DELIMITER = 1;var VARIABLE = 2;var NUMBER = 3;var
TOKEN_SIZE
= 32;var TRUE = -1;var FALSE = 0;function
Expression(theForm,theExpression,Places,Prepend) {places = Places;prepend
=
Prepend;progIndex = 0;prog = theExpression;oForm =
theForm;get_token();if(!token) {serror(2);}Level1();}function Level1(){var
slot;var ttok_type;var temp_token;var result = 0.0;if(tok_type ==
VARIABLE)
{temp_token = token;ttok_type = tok_type;if(typeof oForm[token] !=
"undefined" ) {slot = oForm[token];}else{serror(3);}get_token();if(token
!=
'=') {putback();token = temp_token;tok_type =
ttok_type;}else{get_token();result = Level2();slot.value =
round(result,places);return;}}result=Level2();return result;}function
Level2(){var op = '';var hold = 0;var result = 0;result=Level3();while((op
=
token) == '+' || op == '-') {get_token();hold=Level3();result =
arith(op,result, hold);}return result;}function Level3(){var op = '';var
hold
= 0;var result = 0.0; result = Level4(); while((op = token) == '*' || op
==
'/') {get_token();hold = Level4();result = arith(op,result, hold);}return
result;}function Level4(){var hold = 0;var result = 0;result =
Level5();if((token) == '^') {get_token();hold = Level4();result =
arith('^',result, hold);}return result;}function Level5(){var op = '';var
result = 0.0;op = 0;if((tok_type==DELIMITER) && token == '+' || token ==
'-')
{op = token;get_token();}result = Level6();if(op)result =
unary(op,result);return result;}function Level6(){var result =
0.0;if((token
== '(') && (tok_type == DELIMITER)) {get_token();result =
Level1();if(token
!= ')') { serror(1);} get_token(); } else { result = primitive(); }return
result;}function primitive(){var slot = 0;var result = 0.0;var sValue =
'';var i = 0;switch(tok_type) {case VARIABLE : if(typeof oForm[token] ==
"undefined") { result = 0.0; } else {switch (oForm[token].tagName) {case
'INPUT' : sValue = '0.0';if (oForm[token].type != 'checkbox' )sValue =
oForm[token].value; else if (oForm[token].checked) sValue =
oForm[token].value; while(sValue.charAt(i) == ' ') ++i;
if(sValue.charAt(i)
== '$') { ++i;}sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue)) {serror(4);}result = parseFloat(sValue); if
(isNaN(result)) result = 0; break;case 'SELECT' : sValue =
oForm[token].options[oForm[token].selectedIndex].value;
while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i) == '$') ++i;sValue
=
sValue.substr(i,sValue.length-i); if (!isNumber(sValue)) serror(0);result
=
parseFloat(sValue);if (isNaN(result)) result = 0; break;default:if(
oForm[token].length > 0 ) {for(i=0; i < oForm[token].length; i++)
{if(oForm[token].checked) {sValue =
oForm[token].value;while(sValue.charAt(i) == ' ')
++i;if(sValue.charAt(i)
== '$') ++i; sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue))
serror(4);isNaN(parseFloat(sValue)) ? result += 0 : result +=
parseFloat(sValue); var sType = oForm[token].type.toLowerCase(); sType
=
sType.toLowerCase();if (sType == 'radio')
break;}}}break;}}get_token();return
result;case NUMBER:result = parseFloat(token);get_token();return
result;default:return result;}}
function arith(o,r,h){var t = 0.0;var ex = 0.0; switch(o) { case '-':r =
r -
h; break;case '+': r = r + h; break;case '*': r = r * h;break;case '/':r =
r
/ h;break;case '%':t = ((r) / (h));r = r - (t*(h));break;case '^':ex =
r;if(h==0) { r = 1.0;break;}for(t=h-1; t>0; --t) r = (r) * ex;
break;}return
r;}function unary(o, r){if(o=='-') r = -(r);return r;}function
putback(){var
t = '';t = token;for(;t;t++) progIndex--;}function find_var(s){var temp =
'';temp = oForm.s.value;if( temp == '' ) {return(0.0);}return
parseFloat(temp);}function serror(error){var e = new Array;e[0] = "Syntax
error";e[1] = "Unbalanced parentheses";e[2] = "no expression
present";e[3]
= "Form field does not exist " + token;e[4] = "Not a
number";alert(e[error]
+ ' - ' + token);}function get_token(){var temp = '';tok_type =
0;while(prog.charAt(progIndex) == ' ')
++progIndex;if(is_in(prog.charAt(progIndex), "+-*/%^=()")) {tok_type =
DELIMITER;temp += prog.charAt(progIndex++);} else
if(isAlpha(prog.charAt(progIndex)) || prog.charAt(progIndex) == '$') {
while(!isdelim(prog.charAt(progIndex))) temp +=
prog.charAt(progIndex++);tok_type = VARIABLE;} else if
(isDigit(prog.charAt(progIndex)) || prog.charAt(progIndex) == '.')
{while(!isdelim(prog.charAt(progIndex)))temp +=
prog.charAt(progIndex++);tok_type = NUMBER;}token = temp;}function
isdelim(c){if(is_in(c, "+-/*%^=() ") || c=='\t' || c=='\r')return 1;
return
0;}function isAlpha(c) {var sAlpha =
'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';if
(is_in(c,sAlpha))
return 1; else return 0;}function isDigit(c) {var Digits = '0123456789';
if
(is_in(c,Digits)) return 1; else return 0; }function isNumber(s) {var dec
=
0;var i = 0;if(s.charAt(i) == '-' || s.charAt(i) == '+') ++i;for(i;
i<s.length; i++) { if(!isDigit(s.charAt(i))) {if (s.charAt(i) != '.' ||
dec )
return 0; else ++dec; }}return 1;}function is_in(ch,s){if(s.indexOf(ch)
return 1; else return 0;}function round(number,places) {number =
Math.round(number*Math.pow(10,places))/Math.pow(10,places);number +=
'';var x
= number.lastIndexOf('.'); if (x == -1 && places > 0) { number += '.'; x =
number.length -1; }for ( i = ((number.length-1) - x); i < places; i++)
number
+= '0'; return prepend ? '$' + number : number;}
</script>
<script id="WU_Expression" type="text/javascript" >

// The following code is the property of Webs Unlimited, Inc.
http://www.websunlimited.com
// Copyright 2003
var token = '';var prog = '';var progIndex = 0;var oForm;var places =
2;var
prepend = 0;var DELIMITER = 1;var VARIABLE = 2;var NUMBER = 3;var
TOKEN_SIZE
= 32;var TRUE = -1;var FALSE = 0;function
Expression(theForm,theExpression,Places,Prepend) {places = Places;prepend
=
Prepend;progIndex = 0;prog = theExpression;oForm =
theForm;get_token();if(!token) {serror(2);}Level1();}function Level1(){var
slot;var ttok_type;var temp_token;var result = 0.0;if(tok_type ==
VARIABLE)
{temp_token = token;ttok_type = tok_type;if(typeof oForm[token] !=
"undefined" ) {slot = oForm[token];}else{serror(3);}get_token();if(token
!=
'=') {putback();token = temp_token;tok_type =
ttok_type;}else{get_token();result = Level2();slot.value =
round(result,places);return;}}result=Level2();return result;}function
Level2(){var op = '';var hold = 0;var result = 0;result=Level3();while((op
=
token) == '+' || op == '-') {get_token();hold=Level3();result =
arith(op,result, hold);}return result;}function Level3(){var op = '';var
hold
= 0;var result = 0.0; result = Level4(); while((op = token) == '*' || op
==
'/') {get_token();hold = Level4();result = arith(op,result, hold);}return
result;}function Level4(){var hold = 0;var result = 0;result =
Level5();if((token) == '^') {get_token();hold = Level4();result =
arith('^',result, hold);}return result;}function Level5(){var op = '';var
result = 0.0;op = 0;if((tok_type==DELIMITER) && token == '+' || token ==
'-')
{op = token;get_token();}result = Level6();if(op)result =
unary(op,result);return result;}function Level6(){var result =
0.0;if((token
== '(') && (tok_type == DELIMITER)) {get_token();result =
Level1();if(token
!= ')') { serror(1);} get_token(); } else { result = primitive(); }return
result;}function primitive(){var slot = 0;var result = 0.0;var sValue =
'';var i = 0;switch(tok_type) {case VARIABLE : if(typeof oForm[token] ==
"undefined") { result = 0.0; } else {switch (oForm[token].tagName) {case
'INPUT' : sValue = '0.0';if (oForm[token].type != 'checkbox' )sValue =
oForm[token].value; else if (oForm[token].checked) sValue =
oForm[token].value; while(sValue.charAt(i) == ' ') ++i;
if(sValue.charAt(i)
== '$') { ++i;}sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue)) {serror(4);}result = parseFloat(sValue); if
(isNaN(result)) result = 0; break;case 'SELECT' : sValue =
oForm[token].options[oForm[token].selectedIndex].value;
while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i) == '$') ++i;sValue
=
sValue.substr(i,sValue.length-i); if (!isNumber(sValue)) serror(0);result
=
parseFloat(sValue);if (isNaN(result)) result = 0; break;default:if(
oForm[token].length > 0 ) {for(i=0; i < oForm[token].length; i++)
{if(oForm[token].checked) {sValue =
oForm[token].value;while(sValue.charAt(i) == ' ')
++i;if(sValue.charAt(i)
== '$') ++i; sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue))
serror(4);isNaN(parseFloat(sValue)) ? result += 0 : result +=
parseFloat(sValue); var sType = oForm[token].type.toLowerCase(); sType
=
sType.toLowerCase();if (sType == 'radio')
break;}}}break;}}get_token();return
result;case NUMBER:result = parseFloat(token);get_token();return
result;default:return result;}}
function arith(o,r,h){var t = 0.0;var ex = 0.0; switch(o) { case '-':r =
r -
h; break;case '+': r = r + h; break;case '*': r = r * h;break;case '/':r =
r
/ h;break;case '%':t = ((r) / (h));r = r - (t*(h));break;case '^':ex =
r;if(h==0) { r = 1.0;break;}for(t=h-1; t>0; --t) r = (r) * ex;
break;}return
r;}function unary(o, r){if(o=='-') r = -(r);return r;}function
putback(){var
t = '';t = token;for(;t;t++) progIndex--;}function find_var(s){var temp =
'';temp = oForm.s.value;if( temp == '' ) {return(0.0);}return
parseFloat(temp);}function serror(error){var e = new Array;e[0] = "Syntax
error";e[1] = "Unbalanced parentheses";e[2] = "no expression
present";e[3]
= "Form field does not exist " + token;e[4] = "Not a
number";alert(e[error]
+ ' - ' + token);}function get_token(){var temp = '';tok_type =
0;while(prog.charAt(progIndex) == ' ')
++progIndex;if(is_in(prog.charAt(progIndex), "+-*/%^=()")) {tok_type =
DELIMITER;temp += prog.charAt(progIndex++);} else
if(isAlpha(prog.charAt(progIndex)) || prog.charAt(progIndex) == '$') {
while(!isdelim(prog.charAt(progIndex))) temp +=
prog.charAt(progIndex++);tok_type = VARIABLE;} else if
(isDigit(prog.charAt(progIndex)) || prog.charAt(progIndex) == '.')
{while(!isdelim(prog.charAt(progIndex)))temp +=
prog.charAt(progIndex++);tok_type = NUMBER;}token = temp;}function
isdelim(c){if(is_in(c, "+-/*%^=() ") || c=='\t' || c=='\r')return 1;
return
0;}function isAlpha(c) {var sAlpha =
'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';if
(is_in(c,sAlpha))
return 1; else return 0;}function isDigit(c) {var Digits = '0123456789';
if
(is_in(c,Digits)) return 1; else return 0; }function isNumber(s) {var dec
=
0;var i = 0;if(s.charAt(i) == '-' || s.charAt(i) == '+') ++i;for(i;
i<s.length; i++) { if(!isDigit(s.charAt(i))) {if (s.charAt(i) != '.' ||
dec )
return 0; else ++dec; }}return 1;}function is_in(ch,s){if(s.indexOf(ch)
return 1; else return 0;}function round(number,places) {number =
Math.round(number*Math.pow(10,places))/Math.pow(10,places);number +=
'';var x
= number.lastIndexOf('.'); if (x == -1 && places > 0) { number += '.'; x =
number.length -1; }for ( i = ((number.length-1) - x); i < places; i++)
number
+= '0'; return prepend ? '$' + number : number;}
</script>
</head>

<body background="images/Webbkgnd.jpg">

<p>
<b><font face="CG Omega">
<img border="0" src="images/2003-2005logocolor.gif" width="250"
height="215"><br>
2005 International Convention<br>
Orlando, Florida</font></b></p>

<p>
<i><b><font face="CG Omega" color="#CC00FF">TAB to advance to the next
field
and
calculate subtotals/totals</font></b></i></p>
<form method="POST" action="--WEBBOT-SELF--">
<!--webbot bot="SaveResults" u-file="../_private/form_results.htm"
s-format="HTML/BR" s-label-fields="TRUE" b-reverse-chronology="FALSE"
s-email-format="HTML/BR" b-email-label-fields="TRUE"
b-email-replyto-from-field="FALSE" s-email-replyto="2005 International
Convention Registration" b-email-subject-from-field="FALSE"
s-email-subject="2005 International Convention Registration"
s-builtin-fields
s-email-address="(e-mail address removed)" startspan --><input
TYPE="hidden" NAME="VTI-GROUP" VALUE="0"><!--webbot bot="SaveResults"
endspan
i-checksum="43374" --><hr>
<p><b><font face="CG Omega">1. MEMBER INFORMATION</font></b></p>
<p><font face="CG Omega"><b>Full name: <br>
<input type="text" name="REGISTRANT_Name" size="40"> </b></font> </p>
<p><font face="CG Omega"><b>5-Digit Member ID#:<input type="text"
name="REGISTRANT_ID" size="5"></b></font></p>
<p><font face="CG Omega"><b>State/Province/Nation & Chapter:<br>
<input type="text" name="REGISTRANT_SPN_Chapter"
size="40"></b></font></p>
<p><font face="CG Omega"><b>Address:<br>
<input type="text" name="REGISTRANT_Street_Address"
size="50"></b></font></p>
<p><font face="CG Omega"><b>City, S/P/N, Zip/PC:<br>
<input type="text" name="REGISTRANT_City_SPN_Zip"
size="20"></b></font></p>
<p><font face="CG Omega"><b>First name to appear on badge:<br>
<input type="text" name="REGISTRANT_BadgeName" size="20"></b></font></p>
<p><font face="CG Omega"><b>Daytime Phone:<br>
<input type="text" name="REGISTRANT_phone" size="30"></b></font></p>
<p><font face="CG Omega"><b>E-mail Address:<br>
<input type="text" name="REGISTRANT_email" size="40"></b></font></p>
<p><font face="CG Omega"><b>I am actively employed/engaged in
education:<br>
<input type="radio" value="Yes" name="REGISTRANT_EEinEducation">Yes
<input type="radio" name="REGISTRANT_EEinEducation"
value="No">No</b></font></p>
<hr>
<p><b><font face="CG Omega">2. EMERGENCY CONTACT (NOT Attending
Convention)</font></b></p>
<p><font face="CG Omega"><b>Name: <input type="text"
name="EMERGENCY_CONTACT_Name" size="40"></b></font></p>
<p><font face="CG Omega"><b>Phone: <input type="text"
name="EMERGENCY_CONTACT_phone" size="30"></b></font></p>
<hr>
<p><b><font face="CG Omega">3. CONVENTION REGISTRATION</font></b></p>
<p><b><font face="CG Omega">Pre-registration Policy: To be considered
pre-registered, your
registration must be received by Friday, June 17. After this date, all
registrations and changes must be processed at the Convention
Registration
Desk during the Convention.</font></b></p>
<blockquote>
<p><b><font face="CG Omega">A. Member Registration (Includes EDUCATIONAL
SYMPOSIUM, Name Badge,
Convention Registration Packet, Business Sessions, Speakers, Regional
Luncheon
and Reception, Banquet and Favor.)</font></b></p>
<p><font face="CG Omega"><b>Banquet Choice:<br>
<input type="radio" name="REGISTRANT_BanquetChoice" value="Beef">Beef
<input type="radio" name="REGISTRANT_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="REGISTRANT_BanquetChoice"
value="Vegetarian">Vegetarian</b></font></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>TOTAL<br>
<input type="checkbox" name="MEMBER_CONVENTION_REGISTRATION" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'MEMBER_CONVENTION_REGISTRATION=MEMBER_CONVENTION_REGISTRATION*100+85',2,0);">Convention
Registration submitted by May 1:
$185 </b></font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">B. Educational Symposium ONLY -
Wednesday, July 6</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>TOTAL<br>
<input type="checkbox" name="EDUCATIONAL_SYMPOSIUM_REGISTRATION"
value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'EDUCATIONAL_SYMPOSIUM_REGISTRATION=EDUCATIONAL_SYMPOSIUM_REGISTRATION*45+40',2,0);">Educational
Symposium Registration submitted by May 1:
$85</b></font></p>
<blockquote>
<blockquote>
<p><b><font face="CG Omega">Professional Growth/Fraternity Education
Breakout Session Choices</font></b></p>
<ul>
<li><b><font face="CG Omega"><a target="_blank"
href="Breakout.htm">Click here for session titles
and descriptions.</a></font></b></li>
</ul>
<p><font face="CG Omega"><b>Fill in session numbers, indicating your
first, second and third choices
for each July 6 time slot.<br>
July 6; 11:15 AM-12:15 PM<br>
(Sessions 1-19):<br>
First Choice #<input type="text" name="ES_FIRST_MORNING_SESSION_CHOICE"
size="2">
<br>
Second Choice#<input type="text" name="ES_SECOND_MORNING_SESSION_CHOICE"
size="2">
<br>
Third Choice#<input type="text" name="ES_THIRD_MORNING_SESSION_CHOICE"
size="2"><br>
July 6; 2:45-3:45 PM<br>
(Sessions 20-38):<br>
First Choice #<input type="text" name="ES_FIRST_AFTERNOON_SESSION_CHOICE"
size="2">
<br>
Second Choice#<input type="text"
name="ES_SECOND_AFTERNOON_SESSION_CHOICE"
size="2">
<br>
Third Choice#<input type="text" name="ES_THIRD_AFTERNOON_SESSION_CHOICE"
size="2"></b></font></p>
</blockquote>
</blockquote>
<p align="right"><font face="CG Omega"><b>SESSION 39, Tuesday, July 5,
includes transportation,
<input type="text" name="QTY_SESSION_39" size="2"> at $20
each:
<input type="text" name="SESSION_39_TOTAL" size="7"
onblur="Expression(this.form,'SESSION_39_TOTAL=QTY_SESSION_39*20',2,1);"><br>
SESSION 40, Monday, July 11, includes transportation,
<input type="text" name="QTY_SESSION_40" size="2"> at $20 each:
<input type="text" name="SESSION_40_TOTAL" size="7"
onblur="Expression(this.form,'SESSION_40_TOTAL=QTY_SESSION_40*20',2,1);"></b></font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">C. Optional Special Function
Fees:</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>
<input type="checkbox" name="PAST_SPN_PRESIDENTS_LUNCHEON" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'PAST_SPN_PRESIDENTS_LUNCHEON=PAST_SPN_PRESIDENTS_LUNCHEON*20+5',2,0);">Past
S/P/N Presidents' Luncheon (Past S/P/N Presidents only):
$25<br>
<input type="checkbox" name="LITTLE_WIGS_BREAKFAST" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'LITTLE_WIGS_BREAKFAST=LITTLE_WIGS_BREAKFAST*10+10',2,0);">Little
Wigs Breakfast (Past International Chapter Members): $20</b></font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">D. NONMEMBER GUEST TICKETS<br>
Please specify how many tickets you are purchasing for each
event.</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>Banquet Guest(s) (Not included
in
Alpha Delta Kappa Association Registration Fee),
<input type="text" name="QTY_BANQUET_GUEST" size="2"> at $55 each:
<input type="text" name="BANQUET_GUEST_TOTAL" size="7"
onblur="Expression(this.form,'BANQUET_GUEST_TOTAL=QTY_BANQUET_GUEST*55',2,1);"></b></font></p>
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<p align="left"><font face="CG Omega"><b>Banquet Choice:<br>
<input type="radio" name="GUEST1_BanquetChoice" value="Beef">Beef
<input type="radio" name="GUEST1_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="GUEST1_BanquetChoice"
value="Vegetarian">Vegetarian<br>
<input type="radio" name="GUEST2_BanquetChoice" value="Beef">Beef
<input type="radio" name="GUEST2_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="GUEST2_BanquetChoice"
value="Vegetarian">Vegetarian</b></font></p>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
<p align="right">
<font face="CG Omega"><b>
Regional
Luncheon Guest(s),
<input type="text" name="QTY_REGIONAL_LUNCHEON_GUESTS" size="2"> at $30
each:
<input type="text" name="REGIONAL_LUNCHEON_GUEST_TOTAL" size="7"
onblur="Expression(this.form,'REGIONAL_LUNCHEON_GUEST_TOTAL=QTY_REGIONAL_LUNCHEON_GUESTS*30',2,1);"></b></font></p>
<p align="right"><b><font face="CG Omega">E. ALPHA DELTA KAPPA ASSOC. FOR
MEN CONVENTION
REGISTRATION(S)</font></b><font face="CG Omega"><b> <input
type="text" name="QTY_ADKA_REGISTRATIONS" size="2">
at $40 each:
<input type="text" name="ADKA_REGISTRATION_TOTAL" size="7"
onblur="Expression(this.form,'ADKA_REGISTRATION_TOTAL=QTY_ADKA_REGISTRATIONS*40',2,1);"></b></font><b><font
face="CG Omega"><br>
(Includes Annual Dues, Alpha Delta Kappa Association Breakfast, Reception
and
General Session Speakers. Does not include Banquet. Alpha Delta
Kappa Association tickets may be purchased above for the Banquet and/or
the
Regional Luncheon.)</font></b></p>
<blockquote>
<blockquote>
<p align="left"><font face="CG Omega"><b>Name to appear on badge:
<input type="text" name="ADKA_BADGE_NAME" size="40"><br>
</b></font></p>
</blockquote>
</blockquote>
<p align="right"><font face="CG Omega"><b>Alpha Delta Kappa Association
Membership Dues for Alpha Delta Kappa Association members <br>
NOT ATTENDING CONVENTION, <input type="text" name="QTY_ADKA_DUES"
size="2"> at $6
each:
<input type="text" name="ADKA_DUES_TOTAL" size="3"
onblur="Expression(this.form,'ADKA_DUES_TOTAL=QTY_ADKA_DUES*6',2,1);"></b></font></p>
<blockquote>
<p align="right"><font face="CG Omega"><b>Alpha Delta Kappa Association
member name:<br>
<input type="text" name="ADKA_MEMBER_NAME" size="40"></b></font></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>F. 2005 International
Convention
charm and/or pin: charm(s),
<input type="text" name="QTY_CHARMS" size="2"> at $5 each:
<input type="text" name="CHARM_TOTAL" size="7"
onblur="Expression(this.form,'CHARM_TOTAL=QTY_CHARMS*5',2,1);"><br>
pin(s), <input type="text" name="QTY_PINS" size="2"> at $5 each:
<input type="text" name="PIN_TOTAL" size="7"
onblur="Expression(this.form,'PIN_TOTAL=QTY_PINS*5',2,1);"></b></font></p>
<p align="right"><font face="CG Omega"><b>TOTAL FEE in U.S. FUNDS: (Add
registration, special
functions, guests' tickets and pin/charm)
<input type="text" name="TOTAL_FEE_TO_BE_CHARGED" size="7"
onblur="Expression(this.form,'TOTAL_FEE_TO_BE_CHARGED=MEMBER_CONVENTION_REGISTRATION+EDUCATIONAL_SYMPOSIUM_REGISTRATION+SESSION_39_TOTAL+SESSION_40_TOTAL+PAST_SPN_PRESIDENTS_LUNCHEON+LITTLE_WIGS_BREAKFAST+BANQUET_GUEST_TOTAL+REGIONAL_LUNCHEON_GUEST_TOTAL+ADKA_REGISTRATION_TOTAL+ADKA_DUES_TOTAL+CHARM_TOTAL+PIN_TOTAL',2,1);"></b></font></p>
<p align="left"><b><font face="CG Omega">CANCELLATION POLICY:
Cancellations must be received in writing
by June 17, 2005 to qualify for a refund.</font></b></p>
 
M

MD Webs Unlimited

Hi Laura,

First, I would like to clarify your statements. Form Calc will compute
quantities of one. What your attempting is to use checkboxes in your
calculations which FC does not support.

I provided you with some script that would allow you to support a checkbox
using an expression built on the checkbox field.

I'll be happy to assist you with that via WU support channels. Understand
that this is outside of the normal support offered as FC is functioning as
designed.

--
Mike - FrontPage MVP '97 - '02
Webs Unlimited, Inc
http://www.websunlimited.com
FrontPage Add-in Since '97

Laura C. Bourgeois said:
I bought the WebsUnlimited Form Field calculator for Frontpage 2002 last week.

I need to be able to calculate not only items with possible quantities, but
also items with a quantity of 1 only in the same form. To accomplish this,
I had the following correspondence with Mike from WebsUnlimited on the
Microsoft FrontPage discussion group (I will describe the crux of my problem
beneath the following dialog):

Laura,

You have the calculation on the wrong field it should go on the check box.
Every field that is a part of the calculation will have
to have a calculation.

--
Mike -- FrontPage MVP '97-'02
J-Bots 2004 Released Special Pricing
http://www.websunlimited.com
FrontPage Add-ins Since '97 FP 2003 / 2002 / 2000 Compatible
message
Thank you, Mike! I tried it, and I hope I interpreted your directions
correctly, although apparently I have not. When I click "generate" in the
Form Field Calculator, I get this error: "frmGenericInsert: Insert
ScriptHead 13:Type Mismatch," but it seems to generate anyway.

After adding the code you describe (the total cost of this item is $185),
after I click the check box on the form, the subtotal field remains blank,
even after tabbing through it. Here is the code I ended up with:

<input type="checkbox" name="MEMBER_CONVENTION_REGISTRATION"
value="1">Convention Registration submitted by May 1, $185:
<input type="text" name="MEMBER_CONVENTION_REGISTRATION_BY_MAY1" size="7"
onclick="if (!this.checked) {this.value=0};
"Expression(this.form,'MEMBER_CONVENTION_REGISTRATION_BY_MAY1=MEMBER_CONVENT
ION_REGISTRATION*85+MEMBER_CONVENTION_REGISTRATION_BY_MAY1+100');"> said:
If you have any further diagnosis or suggestions, I would very much
appreciate it! Thanks so much! Laura

With Mike's kind assistance, I thought everything was fixed. The form was
working well when I tested it yesterday. We are testing it thoroughly before
actually putting it on our Website.

However, when staff members tried it today, many got varying bad results.
One staffer got a total of $8731 from sums actually totalling $331. Her
total for the MEMBER_CONVENTION_REGISTRATION checkbox registered $8585,
whereas mine for the same box registers $185, as it should. Another staffer
couldn't get the form to calculate subtotals at all, when tabbing or
clicking.

Why would results be so different on different computers? It is still
working fine on my machine, but apparently not on most others. I am going to
paste the calculation portion of the code for the form below. I would very
much appreciate any help you can give me. I am rather at my wit's end at
this point.

Thank you,
Laura C. Bourgeois

-------------------------------------------------------------------------- ------

<html>

<head>
<meta http-equiv="Content-Language" content="en-us">
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>2005 International Convention Orlando</title>
<script id="WU_Expression" type="text/javascript" >

// The following code is the property of Webs Unlimited, Inc.
http://www.websunlimited.com
// Copyright 2003
var token = '';var prog = '';var progIndex = 0;var oForm;var places = 2;var
prepend = 0;var DELIMITER = 1;var VARIABLE = 2;var NUMBER = 3;var TOKEN_SIZE
= 32;var TRUE = -1;var FALSE = 0;function
Expression(theForm,theExpression,Places,Prepend) {places = Places;prepend =
Prepend;progIndex = 0;prog = theExpression;oForm =
theForm;get_token();if(!token) {serror(2);}Level1();}function Level1(){var
slot;var ttok_type;var temp_token;var result = 0.0;if(tok_type == VARIABLE)
{temp_token = token;ttok_type = tok_type;if(typeof oForm[token] !=
"undefined" ) {slot = oForm[token];}else{serror(3);}get_token();if(token !=
'=') {putback();token = temp_token;tok_type =
ttok_type;}else{get_token();result = Level2();slot.value =
round(result,places);return;}}result=Level2();return result;}function
Level2(){var op = '';var hold = 0;var result = 0;result=Level3();while((op =
token) == '+' || op == '-') {get_token();hold=Level3();result =
arith(op,result, hold);}return result;}function Level3(){var op = '';var hold
= 0;var result = 0.0; result = Level4(); while((op = token) == '*' || op ==
'/') {get_token();hold = Level4();result = arith(op,result, hold);}return
result;}function Level4(){var hold = 0;var result = 0;result =
Level5();if((token) == '^') {get_token();hold = Level4();result =
arith('^',result, hold);}return result;}function Level5(){var op = '';var
result = 0.0;op = 0;if((tok_type==DELIMITER) && token == '+' || token == '-')
{op = token;get_token();}result = Level6();if(op)result =
unary(op,result);return result;}function Level6(){var result = 0.0;if((token
== '(') && (tok_type == DELIMITER)) {get_token();result = Level1();if(token
!= ')') { serror(1);} get_token(); } else { result = primitive(); }return
result;}function primitive(){var slot = 0;var result = 0.0;var sValue =
'';var i = 0;switch(tok_type) {case VARIABLE : if(typeof oForm[token] ==
"undefined") { result = 0.0; } else {switch (oForm[token].tagName) {case
'INPUT' : sValue = '0.0';if (oForm[token].type != 'checkbox' )sValue =
oForm[token].value; else if (oForm[token].checked) sValue =
oForm[token].value; while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i)
== '$') { ++i;}sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue)) {serror(4);}result = parseFloat(sValue); if
(isNaN(result)) result = 0; break;case 'SELECT' : sValue =
oForm[token].options[oForm[token].selectedIndex].value;
while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i) == '$') ++i;sValue =
sValue.substr(i,sValue.length-i); if (!isNumber(sValue)) serror(0);result =
parseFloat(sValue);if (isNaN(result)) result = 0; break;default:if(
oForm[token].length > 0 ) {for(i=0; i < oForm[token].length; i++)
{if(oForm[token].checked) {sValue =
oForm[token].value;while(sValue.charAt(i) == ' ') ++i;if(sValue.charAt(i)
== '$') ++i; sValue = sValue.substr(i,sValue.length-i);if (!isNumber(sValue))
serror(4);isNaN(parseFloat(sValue)) ? result += 0 : result +=
parseFloat(sValue); var sType = oForm[token].type.toLowerCase(); sType =
sType.toLowerCase();if (sType == 'radio') break;}}}break;}}get_token();return
result;case NUMBER:result = parseFloat(token);get_token();return
result;default:return result;}}
function arith(o,r,h){var t = 0.0;var ex = 0.0; switch(o) { case '-':r = r -
h; break;case '+': r = r + h; break;case '*': r = r * h;break;case '/':r = r
/ h;break;case '%':t = ((r) / (h));r = r - (t*(h));break;case '^':ex =
r;if(h==0) { r = 1.0;break;}for(t=h-1; t>0; --t) r = (r) * ex; break;}return
r;}function unary(o, r){if(o=='-') r = -(r);return r;}function putback(){var
t = '';t = token;for(;t;t++) progIndex--;}function find_var(s){var temp =
'';temp = oForm.s.value;if( temp == '' ) {return(0.0);}return
parseFloat(temp);}function serror(error){var e = new Array;e[0] = "Syntax
error";e[1] = "Unbalanced parentheses";e[2] = "no expression present";e[3]
= "Form field does not exist " + token;e[4] = "Not a number";alert(e[error]
+ ' - ' + token);}function get_token(){var temp = '';tok_type =
0;while(prog.charAt(progIndex) == ' ')
++progIndex;if(is_in(prog.charAt(progIndex), "+-*/%^=()")) {tok_type =
DELIMITER;temp += prog.charAt(progIndex++);} else
if(isAlpha(prog.charAt(progIndex)) || prog.charAt(progIndex) == '$') {
while(!isdelim(prog.charAt(progIndex))) temp +=
prog.charAt(progIndex++);tok_type = VARIABLE;} else if
(isDigit(prog.charAt(progIndex)) || prog.charAt(progIndex) == '.')
{while(!isdelim(prog.charAt(progIndex)))temp +=
prog.charAt(progIndex++);tok_type = NUMBER;}token = temp;}function
isdelim(c){if(is_in(c, "+-/*%^=() ") || c=='\t' || c=='\r')return 1; return
0;}function isAlpha(c) {var sAlpha =
'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';if (is_in(c,sAlpha))
return 1; else return 0;}function isDigit(c) {var Digits = '0123456789'; if
(is_in(c,Digits)) return 1; else return 0; }function isNumber(s) {var dec =
0;var i = 0;if(s.charAt(i) == '-' || s.charAt(i) == '+') ++i;for(i;
i<s.length; i++) { if(!isDigit(s.charAt(i))) {if (s.charAt(i) != '.' || dec )
return 0; else ++dec; }}return 1;}function is_in(ch,s){if(s.indexOf(ch)
-1)
return 1; else return 0;}function round(number,places) {number =
Math.round(number*Math.pow(10,places))/Math.pow(10,places);number += '';var x
= number.lastIndexOf('.'); if (x == -1 && places > 0) { number += '.'; x =
number.length -1; }for ( i = ((number.length-1) - x); i < places; i++) number
+= '0'; return prepend ? '$' + number : number;}
</script>
<script id="WU_Expression" type="text/javascript" >

// The following code is the property of Webs Unlimited, Inc.
http://www.websunlimited.com
// Copyright 2003
var token = '';var prog = '';var progIndex = 0;var oForm;var places = 2;var
prepend = 0;var DELIMITER = 1;var VARIABLE = 2;var NUMBER = 3;var TOKEN_SIZE
= 32;var TRUE = -1;var FALSE = 0;function
Expression(theForm,theExpression,Places,Prepend) {places = Places;prepend =
Prepend;progIndex = 0;prog = theExpression;oForm =
theForm;get_token();if(!token) {serror(2);}Level1();}function Level1(){var
slot;var ttok_type;var temp_token;var result = 0.0;if(tok_type == VARIABLE)
{temp_token = token;ttok_type = tok_type;if(typeof oForm[token] !=
"undefined" ) {slot = oForm[token];}else{serror(3);}get_token();if(token !=
'=') {putback();token = temp_token;tok_type =
ttok_type;}else{get_token();result = Level2();slot.value =
round(result,places);return;}}result=Level2();return result;}function
Level2(){var op = '';var hold = 0;var result = 0;result=Level3();while((op =
token) == '+' || op == '-') {get_token();hold=Level3();result =
arith(op,result, hold);}return result;}function Level3(){var op = '';var hold
= 0;var result = 0.0; result = Level4(); while((op = token) == '*' || op ==
'/') {get_token();hold = Level4();result = arith(op,result, hold);}return
result;}function Level4(){var hold = 0;var result = 0;result =
Level5();if((token) == '^') {get_token();hold = Level4();result =
arith('^',result, hold);}return result;}function Level5(){var op = '';var
result = 0.0;op = 0;if((tok_type==DELIMITER) && token == '+' || token == '-')
{op = token;get_token();}result = Level6();if(op)result =
unary(op,result);return result;}function Level6(){var result = 0.0;if((token
== '(') && (tok_type == DELIMITER)) {get_token();result = Level1();if(token
!= ')') { serror(1);} get_token(); } else { result = primitive(); }return
result;}function primitive(){var slot = 0;var result = 0.0;var sValue =
'';var i = 0;switch(tok_type) {case VARIABLE : if(typeof oForm[token] ==
"undefined") { result = 0.0; } else {switch (oForm[token].tagName) {case
'INPUT' : sValue = '0.0';if (oForm[token].type != 'checkbox' )sValue =
oForm[token].value; else if (oForm[token].checked) sValue =
oForm[token].value; while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i)
== '$') { ++i;}sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue)) {serror(4);}result = parseFloat(sValue); if
(isNaN(result)) result = 0; break;case 'SELECT' : sValue =
oForm[token].options[oForm[token].selectedIndex].value;
while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i) == '$') ++i;sValue =
sValue.substr(i,sValue.length-i); if (!isNumber(sValue)) serror(0);result =
parseFloat(sValue);if (isNaN(result)) result = 0; break;default:if(
oForm[token].length > 0 ) {for(i=0; i < oForm[token].length; i++)
{if(oForm[token].checked) {sValue =
oForm[token].value;while(sValue.charAt(i) == ' ') ++i;if(sValue.charAt(i)
== '$') ++i; sValue = sValue.substr(i,sValue.length-i);if (!isNumber(sValue))
serror(4);isNaN(parseFloat(sValue)) ? result += 0 : result +=
parseFloat(sValue); var sType = oForm[token].type.toLowerCase(); sType =
sType.toLowerCase();if (sType == 'radio') break;}}}break;}}get_token();return
result;case NUMBER:result = parseFloat(token);get_token();return
result;default:return result;}}
function arith(o,r,h){var t = 0.0;var ex = 0.0; switch(o) { case '-':r = r -
h; break;case '+': r = r + h; break;case '*': r = r * h;break;case '/':r = r
/ h;break;case '%':t = ((r) / (h));r = r - (t*(h));break;case '^':ex =
r;if(h==0) { r = 1.0;break;}for(t=h-1; t>0; --t) r = (r) * ex; break;}return
r;}function unary(o, r){if(o=='-') r = -(r);return r;}function putback(){var
t = '';t = token;for(;t;t++) progIndex--;}function find_var(s){var temp =
'';temp = oForm.s.value;if( temp == '' ) {return(0.0);}return
parseFloat(temp);}function serror(error){var e = new Array;e[0] = "Syntax
error";e[1] = "Unbalanced parentheses";e[2] = "no expression present";e[3]
= "Form field does not exist " + token;e[4] = "Not a number";alert(e[error]
+ ' - ' + token);}function get_token(){var temp = '';tok_type =
0;while(prog.charAt(progIndex) == ' ')
++progIndex;if(is_in(prog.charAt(progIndex), "+-*/%^=()")) {tok_type =
DELIMITER;temp += prog.charAt(progIndex++);} else
if(isAlpha(prog.charAt(progIndex)) || prog.charAt(progIndex) == '$') {
while(!isdelim(prog.charAt(progIndex))) temp +=
prog.charAt(progIndex++);tok_type = VARIABLE;} else if
(isDigit(prog.charAt(progIndex)) || prog.charAt(progIndex) == '.')
{while(!isdelim(prog.charAt(progIndex)))temp +=
prog.charAt(progIndex++);tok_type = NUMBER;}token = temp;}function
isdelim(c){if(is_in(c, "+-/*%^=() ") || c=='\t' || c=='\r')return 1; return
0;}function isAlpha(c) {var sAlpha =
'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';if (is_in(c,sAlpha))
return 1; else return 0;}function isDigit(c) {var Digits = '0123456789'; if
(is_in(c,Digits)) return 1; else return 0; }function isNumber(s) {var dec =
0;var i = 0;if(s.charAt(i) == '-' || s.charAt(i) == '+') ++i;for(i;
i<s.length; i++) { if(!isDigit(s.charAt(i))) {if (s.charAt(i) != '.' || dec )
return 0; else ++dec; }}return 1;}function is_in(ch,s){if(s.indexOf(ch)
-1)
return 1; else return 0;}function round(number,places) {number =
Math.round(number*Math.pow(10,places))/Math.pow(10,places);number += '';var x
= number.lastIndexOf('.'); if (x == -1 && places > 0) { number += '.'; x =
number.length -1; }for ( i = ((number.length-1) - x); i < places; i++) number
+= '0'; return prepend ? '$' + number : number;}
</script>
</head>

<body background="images/Webbkgnd.jpg">

<p>
<b><font face="CG Omega">
<img border="0" src="images/2003-2005logocolor.gif" width="250"
height="215"><br>
2005 International Convention<br>
Orlando, Florida</font></b></p>

<p>
<i><b><font face="CG Omega" color="#CC00FF">TAB to advance to the next field
and
calculate subtotals/totals</font></b></i></p>
<form method="POST" action="--WEBBOT-SELF--">
<!--webbot bot="SaveResults" u-file="../_private/form_results.htm"
s-format="HTML/BR" s-label-fields="TRUE" b-reverse-chronology="FALSE"
s-email-format="HTML/BR" b-email-label-fields="TRUE"
b-email-replyto-from-field="FALSE" s-email-replyto="2005 International
Convention Registration" b-email-subject-from-field="FALSE"
s-email-subject="2005 International Convention Registration" s-builtin-fields
s-email-address="(e-mail address removed)" startspan --><input
TYPE="hidden" NAME="VTI-GROUP" VALUE="0"><!--webbot bot="SaveResults" endspan
i-checksum="43374" --><hr>
<p><b><font face="CG Omega">1. MEMBER INFORMATION</font></b></p>
<p><font face="CG Omega"><b>Full name: <br>
<input type="text" name="REGISTRANT_Name" size="40"> </b></font> </p>
<p><font face="CG Omega"><b>5-Digit Member ID#:<input type="text"
name="REGISTRANT_ID" size="5"></b></font></p>
<p><font face="CG Omega"><b>State/Province/Nation & Chapter:<br>
<input type="text" name="REGISTRANT_SPN_Chapter"

size="40"> said:
<p><font face="CG Omega"><b>Address:<br>
<input type="text" name="REGISTRANT_Street_Address"
size="50"></b></font></p>
<p><font face="CG Omega"><b>City, S/P/N, Zip/PC:<br>
<input type="text" name="REGISTRANT_City_SPN_Zip"
size="20"> said:
<p><font face="CG Omega"><b>First name to appear on badge:<br>
<input type="text" name="REGISTRANT_BadgeName" size="20"></b></font></p>
<p><font face="CG Omega"><b>Daytime Phone:<br>
<input type="text" name="REGISTRANT_phone" size="30"></b></font></p>
<p><font face="CG Omega"><b>E-mail Address:<br>
<input type="text" name="REGISTRANT_email" size="40"></b></font></p>
<p><font face="CG Omega"><b>I am actively employed/engaged in
education: said:
<input type="radio" value="Yes" name="REGISTRANT_EEinEducation">Yes
<input type="radio" name="REGISTRANT_EEinEducation"
value="No">No</b></font></p>
<hr>
<p><b><font face="CG Omega">2. EMERGENCY CONTACT (NOT Attending
Convention)</font></b></p>
<p><font face="CG Omega"><b>Name: <input type="text"
name="EMERGENCY_CONTACT_Name" size="40"></b></font></p>
<p><font face="CG Omega"><b>Phone: <input type="text"
name="EMERGENCY_CONTACT_phone" size="30"></b></font></p>
<hr>
<p><b><font face="CG Omega">3. CONVENTION REGISTRATION</font></b></p>
<p><b><font face="CG Omega">Pre-registration Policy: To be considered
pre-registered, your
registration must be received by Friday, June 17. After this date, all
registrations and changes must be processed at the Convention Registration
Desk during the Convention.</font></b></p>
<blockquote>
<p><b><font face="CG Omega">A. Member Registration (Includes EDUCATIONAL
SYMPOSIUM, Name Badge,
Convention Registration Packet, Business Sessions, Speakers, Regional
Luncheon
and Reception, Banquet and Favor.)</font></b></p>
<p><font face="CG Omega"><b>Banquet Choice:<br>
<input type="radio" name="REGISTRANT_BanquetChoice" value="Beef">Beef
<input type="radio" name="REGISTRANT_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="REGISTRANT_BanquetChoice"
value="Vegetarian">Vegetarian</b></font></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>TOTAL<br>
<input type="checkbox" name="MEMBER_CONVENTION_REGISTRATION" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'MEMBER_CONVENTION_REGISTRATION=MEMBER_CONVENTION_REGIS
TRATION*100+85',2,0);">Convention Registration submitted by May 1:
$185 </b></font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">B. Educational Symposium ONLY -
Wednesday, July 6</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>TOTAL<br>
<input type="checkbox" name="EDUCATIONAL_SYMPOSIUM_REGISTRATION" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'EDUCATIONAL_SYMPOSIUM_REGISTRATION=EDUCATIONAL_SYMPOSI
UM_REGISTRATION*45+40',2,0);">Educational
Symposium Registration submitted by May 1:
$85</b></font></p>
<blockquote>
<blockquote>
<p><b><font face="CG Omega">Professional Growth/Fraternity Education
Breakout Session Choices</font></b></p>
<ul>
<li><b><font face="CG Omega"><a target="_blank"
href="Breakout.htm">Click here for session titles
and descriptions.</a></font></b></li>
</ul>
<p><font face="CG Omega"><b>Fill in session numbers, indicating your
first, second and third choices
for each July 6 time slot.<br>
July 6; 11:15 AM-12:15 PM<br>
(Sessions 1-19):<br>
First Choice #<input type="text" name="ES_FIRST_MORNING_SESSION_CHOICE"
size="2">
<br>
Second Choice#<input type="text" name="ES_SECOND_MORNING_SESSION_CHOICE"
size="2">
<br>
Third Choice#<input type="text" name="ES_THIRD_MORNING_SESSION_CHOICE"
size="2"><br>
July 6; 2:45-3:45 PM<br>
(Sessions 20-38):<br>
First Choice #<input type="text" name="ES_FIRST_AFTERNOON_SESSION_CHOICE"
size="2">
<br>
Second Choice#<input type="text" name="ES_SECOND_AFTERNOON_SESSION_CHOICE"
size="2">
<br>
Third Choice#<input type="text" name="ES_THIRD_AFTERNOON_SESSION_CHOICE"
size="2"></b></font></p>
</blockquote>
</blockquote>
<p align="right"><font face="CG Omega"><b>SESSION 39, Tuesday, July 5,
includes transportation,
<input type="text" name="QTY_SESSION_39" size="2"> at $20
each:
<input type="text" name="SESSION_39_TOTAL" size="7"
onblur="Expression(this.form,'SESSION_39_TOTAL=QTY_SESSION_39*20',2,1);"><br

SESSION 40, Monday, July 11, includes transportation,
<input type="text" name="QTY_SESSION_40" size="2"> at $20 each:
<input type="text" name="SESSION_40_TOTAL" size="7"
onblur="Expression(this.form,'SESSION_40_TOTAL=QTY_SESSION_40*20',2,1);"></b
</font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">C. Optional Special Function
Fees:</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>
<input type="checkbox" name="PAST_SPN_PRESIDENTS_LUNCHEON" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'PAST_SPN_PRESIDENTS_LUNCHEON=PAST_SPN_PRESIDENTS_LUNCH
EON*20+5',2,0);">Past S/P/N Presidents' Luncheon (Past S/P/N Presidents
only):
$25<br>
<input type="checkbox" name="LITTLE_WIGS_BREAKFAST" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'LITTLE_WIGS_BREAKFAST=LITTLE_WIGS_BREAKFAST*10+10',2,0
);">Little
Wigs Breakfast (Past International Chapter Members): $20</b></font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">D. NONMEMBER GUEST TICKETS<br>
Please specify how many tickets you are purchasing for each
event.</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>Banquet Guest(s) (Not included in
Alpha Delta Kappa Association Registration Fee),
<input type="text" name="QTY_BANQUET_GUEST" size="2"> at $55 each:
<input type="text" name="BANQUET_GUEST_TOTAL" size="7"
onblur="Expression(this.form,'BANQUET_GUEST_TOTAL=QTY_BANQUET_GUEST*55',2,1)
;"> said:
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<p align="left"><font face="CG Omega"><b>Banquet Choice:<br>
<input type="radio" name="GUEST1_BanquetChoice" value="Beef">Beef
<input type="radio" name="GUEST1_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="GUEST1_BanquetChoice"
value="Vegetarian">Vegetarian<br>
<input type="radio" name="GUEST2_BanquetChoice" value="Beef">Beef
<input type="radio" name="GUEST2_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="GUEST2_BanquetChoice"
value="Vegetarian">Vegetarian</b></font></p>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
<p align="right">
<font face="CG Omega"><b>
Regional
Luncheon Guest(s),
<input type="text" name="QTY_REGIONAL_LUNCHEON_GUESTS" size="2"> at $30
each:
<input type="text" name="REGIONAL_LUNCHEON_GUEST_TOTAL" size="7"
onblur="Expression(this.form,'REGIONAL_LUNCHEON_GUEST_TOTAL=QTY_REGIONAL_LUN
CHEON_GUESTS*30' said:
<p align="right"><b><font face="CG Omega">E. ALPHA DELTA KAPPA ASSOC. FOR
MEN CONVENTION
REGISTRATION(S)</font></b><font face="CG Omega"><b> <input
type="text" name="QTY_ADKA_REGISTRATIONS" size="2">
at $40 each:
<input type="text" name="ADKA_REGISTRATION_TOTAL" size="7"
onblur="Expression(this.form,'ADKA_REGISTRATION_TOTAL=QTY_ADKA_REGISTRATIONS
*40' said:
(Includes Annual Dues, Alpha Delta Kappa Association Breakfast, Reception
and
General Session Speakers. Does not include Banquet. Alpha Delta
Kappa Association tickets may be purchased above for the Banquet and/or the
Regional Luncheon.)</font></b></p>
<blockquote>
<blockquote>
<p align="left"><font face="CG Omega"><b>Name to appear on badge:
<input type="text" name="ADKA_BADGE_NAME" size="40"><br>
</b></font></p>
</blockquote>
</blockquote>
<p align="right"><font face="CG Omega"><b>Alpha Delta Kappa Association
Membership Dues for Alpha Delta Kappa Association members <br>
NOT ATTENDING CONVENTION, <input type="text" name="QTY_ADKA_DUES"
size="2"> at $6
each:
<input type="text" name="ADKA_DUES_TOTAL" size="3"
onblur="Expression(this.form said:
<blockquote>
<p align="right"><font face="CG Omega"><b>Alpha Delta Kappa Association
member name:<br>
<input type="text" name="ADKA_MEMBER_NAME" size="40"></b></font></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>F. 2005 International Convention
charm and/or pin: charm(s),
<input type="text" name="QTY_CHARMS" size="2"> at $5 each:
<input type="text" name="CHARM_TOTAL" size="7"
onblur="Expression(this.form,'CHARM_TOTAL=QTY_CHARMS*5',2,1);"><br>
pin(s), <input type="text" name="QTY_PINS" size="2"> at $5 each:
<input type="text" name="PIN_TOTAL" size="7"
onblur="Expression(this.form,'PIN_TOTAL=QTY_PINS*5',2,1);"></b></font></p>
<p align="right"><font face="CG Omega"><b>TOTAL FEE in U.S. FUNDS: (Add
registration, special
functions, guests' tickets and pin/charm)
<input type="text" name="TOTAL_FEE_TO_BE_CHARGED" size="7"

onblur="Expression(this.form,'TOTAL_FEE_TO_BE_CHARGED=MEMBER_CONVENTION_REGI
STRATION+EDUCATIONAL_SYMPOSIUM_REGISTRATION+SESSION_39_TOTAL+SESSION_40_TOTA
L+PAST_SPN_PRESIDENTS_LUNCHEON+LITTLE_WIGS_BREAKFAST+BANQUET_GUEST_TOTAL+REG
IONAL_LUNCHEON_GUEST_TOTAL+ADKA_REGISTRATION_TOTAL+ADKA_DUES_TOTAL+CHARM_TOT
 
M

MD Webs Unlimited

Jon,

There is nothing to fix. What Laura wishes to accomplish is not a part of
FC. I provided her with code that would allow here to accomplish what she
wish but it appears that she is struggling with it.

You said, "...at least I - as "probably" the most knowledgeable javascript
guy in the group..." I see that you have a strong ego ;>)

--
Mike -- FrontPage '97 - '02
Webs Unlimited, Inc
http://www.websunlimited.com
FrontPage Add-in Since '97

Jon Spivey said:
Hi Laura,
You really should address this issue with Mike himself - he's a competent
programmer who's sold you a product so he should support it. If you can't
get a sensible response from him ditch the product then post back and we'll
help you out - but we (or at least I - as "probably" the most knowledgable
javascript guy in the group) draw the line at fixing code sold to you by
someone else.

--
Cheers,
Jon
Microsoft MVP

in message news:[email protected]...
I bought the WebsUnlimited Form Field calculator for Frontpage 2002 last
week.

I need to be able to calculate not only items with possible quantities,
but
also items with a quantity of 1 only in the same form. To accomplish
this,
I had the following correspondence with Mike from WebsUnlimited on the
Microsoft FrontPage discussion group (I will describe the crux of my
problem
beneath the following dialog):

Laura,

You have the calculation on the wrong field it should go on the check box.
Every field that is a part of the calculation will have
to have a calculation.

--
Mike -- FrontPage MVP '97-'02
J-Bots 2004 Released Special Pricing
http://www.websunlimited.com
FrontPage Add-ins Since '97 FP 2003 / 2002 / 2000 Compatible
message
"Expression(this.form,'MEMBER_CONVENTION_REGISTRATION_BY_MAY1=MEMBER_CONVENT
ION_REGISTRATION*85+MEMBER_CONVENTION_REGISTRATION_BY_MAY1+100');"> said:
If you have any further diagnosis or suggestions, I would very much
appreciate it! Thanks so much! Laura

:

Laura,

I've been thinking about this question and even though the functionality
is not intrinsic to Form Calc you can accomplish it with
a little bit of extra code.

1. Change the value of the check box from "on" to "1"
2. Create the FC expression using the onclick event for the checkbox
using C1*5.95+T1+30.45 ..... where C1 is the checkbox and T1
is another field in the expression.

There is the fun part -- you'll need to add the following code to the
onclick event of the check box

onclick="if (!this.checked) {this.value=0};
Expression(this.form,"C1*5.95+T1*30.95);"

HTH,


--
Mike -- FrontPage MVP '97-'02
J-Bots 2004 Released Special Pricing
http://www.websunlimited.com
FrontPage Add-ins Since '97 FP 2003 / 2002 / 2000 Compatible



message
I am working in FrontPage 2002. I am building a convention
registration
form. Most items on the form may be purchased in quantities of one or
more.
I bought the Form Field Calculator from WebsUnlimited to help me with
those
subtotals and the grand total and it works beautifully. However, it
does not
support check boxes or radio buttons (as I just heard from WU tech
support).
There are four items on the form that are optional to purchase; but if
purchased, only one may be purchased. We want to make it impossible
for more
than one to be purchased. Ideally, a user would click a check box to
purchase the single item, and the correct total would appear in the
subtotal
box, as it does with the subtotal fields that calculate off a quantity
of one
or more. I would very much appreciate any ideas; I am stumped and
frustrated! Thanks so much!

With Mike's kind assistance, I thought everything was fixed. The form was
working well when I tested it yesterday. We are testing it thoroughly
before
actually putting it on our Website.

However, when staff members tried it today, many got varying bad results.
One staffer got a total of $8731 from sums actually totalling $331. Her
total for the MEMBER_CONVENTION_REGISTRATION checkbox registered $8585,
whereas mine for the same box registers $185, as it should. Another
staffer
couldn't get the form to calculate subtotals at all, when tabbing or
clicking.

Why would results be so different on different computers? It is still
working fine on my machine, but apparently not on most others. I am going
to
paste the calculation portion of the code for the form below. I would
very
much appreciate any help you can give me. I am rather at my wit's end at
this point.

Thank you,
Laura C. Bourgeois

-------------------------------------------------------------------------- ------

<html>

<head>
<meta http-equiv="Content-Language" content="en-us">
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>2005 International Convention Orlando</title>
<script id="WU_Expression" type="text/javascript" >

// The following code is the property of Webs Unlimited, Inc.
http://www.websunlimited.com
// Copyright 2003
var token = '';var prog = '';var progIndex = 0;var oForm;var places =
2;var
prepend = 0;var DELIMITER = 1;var VARIABLE = 2;var NUMBER = 3;var
TOKEN_SIZE
= 32;var TRUE = -1;var FALSE = 0;function
Expression(theForm,theExpression,Places,Prepend) {places = Places;prepend
=
Prepend;progIndex = 0;prog = theExpression;oForm =
theForm;get_token();if(!token) {serror(2);}Level1();}function Level1(){var
slot;var ttok_type;var temp_token;var result = 0.0;if(tok_type ==
VARIABLE)
{temp_token = token;ttok_type = tok_type;if(typeof oForm[token] !=
"undefined" ) {slot = oForm[token];}else{serror(3);}get_token();if(token
!=
'=') {putback();token = temp_token;tok_type =
ttok_type;}else{get_token();result = Level2();slot.value =
round(result,places);return;}}result=Level2();return result;}function
Level2(){var op = '';var hold = 0;var result = 0;result=Level3();while((op
=
token) == '+' || op == '-') {get_token();hold=Level3();result =
arith(op,result, hold);}return result;}function Level3(){var op = '';var
hold
= 0;var result = 0.0; result = Level4(); while((op = token) == '*' || op
==
'/') {get_token();hold = Level4();result = arith(op,result, hold);}return
result;}function Level4(){var hold = 0;var result = 0;result =
Level5();if((token) == '^') {get_token();hold = Level4();result =
arith('^',result, hold);}return result;}function Level5(){var op = '';var
result = 0.0;op = 0;if((tok_type==DELIMITER) && token == '+' || token ==
'-')
{op = token;get_token();}result = Level6();if(op)result =
unary(op,result);return result;}function Level6(){var result =
0.0;if((token
== '(') && (tok_type == DELIMITER)) {get_token();result =
Level1();if(token
!= ')') { serror(1);} get_token(); } else { result = primitive(); }return
result;}function primitive(){var slot = 0;var result = 0.0;var sValue =
'';var i = 0;switch(tok_type) {case VARIABLE : if(typeof oForm[token] ==
"undefined") { result = 0.0; } else {switch (oForm[token].tagName) {case
'INPUT' : sValue = '0.0';if (oForm[token].type != 'checkbox' )sValue =
oForm[token].value; else if (oForm[token].checked) sValue =
oForm[token].value; while(sValue.charAt(i) == ' ') ++i;
if(sValue.charAt(i)
== '$') { ++i;}sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue)) {serror(4);}result = parseFloat(sValue); if
(isNaN(result)) result = 0; break;case 'SELECT' : sValue =
oForm[token].options[oForm[token].selectedIndex].value;
while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i) == '$') ++i;sValue
=
sValue.substr(i,sValue.length-i); if (!isNumber(sValue)) serror(0);result
=
parseFloat(sValue);if (isNaN(result)) result = 0; break;default:if(
oForm[token].length > 0 ) {for(i=0; i < oForm[token].length; i++)
{if(oForm[token].checked) {sValue =
oForm[token].value;while(sValue.charAt(i) == ' ')
++i;if(sValue.charAt(i)
== '$') ++i; sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue))
serror(4);isNaN(parseFloat(sValue)) ? result += 0 : result +=
parseFloat(sValue); var sType = oForm[token].type.toLowerCase(); sType
=
sType.toLowerCase();if (sType == 'radio')
break;}}}break;}}get_token();return
result;case NUMBER:result = parseFloat(token);get_token();return
result;default:return result;}}
function arith(o,r,h){var t = 0.0;var ex = 0.0; switch(o) { case '-':r =
r -
h; break;case '+': r = r + h; break;case '*': r = r * h;break;case '/':r =
r
/ h;break;case '%':t = ((r) / (h));r = r - (t*(h));break;case '^':ex =
r;if(h==0) { r = 1.0;break;}for(t=h-1; t>0; --t) r = (r) * ex;
break;}return
r;}function unary(o, r){if(o=='-') r = -(r);return r;}function
putback(){var
t = '';t = token;for(;t;t++) progIndex--;}function find_var(s){var temp =
'';temp = oForm.s.value;if( temp == '' ) {return(0.0);}return
parseFloat(temp);}function serror(error){var e = new Array;e[0] = "Syntax
error";e[1] = "Unbalanced parentheses";e[2] = "no expression
present";e[3]
= "Form field does not exist " + token;e[4] = "Not a
number";alert(e[error]
+ ' - ' + token);}function get_token(){var temp = '';tok_type =
0;while(prog.charAt(progIndex) == ' ')
++progIndex;if(is_in(prog.charAt(progIndex), "+-*/%^=()")) {tok_type =
DELIMITER;temp += prog.charAt(progIndex++);} else
if(isAlpha(prog.charAt(progIndex)) || prog.charAt(progIndex) == '$') {
while(!isdelim(prog.charAt(progIndex))) temp +=
prog.charAt(progIndex++);tok_type = VARIABLE;} else if
(isDigit(prog.charAt(progIndex)) || prog.charAt(progIndex) == '.')
{while(!isdelim(prog.charAt(progIndex)))temp +=
prog.charAt(progIndex++);tok_type = NUMBER;}token = temp;}function
isdelim(c){if(is_in(c, "+-/*%^=() ") || c=='\t' || c=='\r')return 1;
return
0;}function isAlpha(c) {var sAlpha =
'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';if
(is_in(c,sAlpha))
return 1; else return 0;}function isDigit(c) {var Digits = '0123456789';
if
(is_in(c,Digits)) return 1; else return 0; }function isNumber(s) {var dec
=
0;var i = 0;if(s.charAt(i) == '-' || s.charAt(i) == '+') ++i;for(i;
i<s.length; i++) { if(!isDigit(s.charAt(i))) {if (s.charAt(i) != '.' ||
dec )
return 0; else ++dec; }}return 1;}function is_in(ch,s){if(s.indexOf(ch)
return 1; else return 0;}function round(number,places) {number =
Math.round(number*Math.pow(10,places))/Math.pow(10,places);number +=
'';var x
= number.lastIndexOf('.'); if (x == -1 && places > 0) { number += '.'; x =
number.length -1; }for ( i = ((number.length-1) - x); i < places; i++)
number
+= '0'; return prepend ? '$' + number : number;}
</script>
<script id="WU_Expression" type="text/javascript" >

// The following code is the property of Webs Unlimited, Inc.
http://www.websunlimited.com
// Copyright 2003
var token = '';var prog = '';var progIndex = 0;var oForm;var places =
2;var
prepend = 0;var DELIMITER = 1;var VARIABLE = 2;var NUMBER = 3;var
TOKEN_SIZE
= 32;var TRUE = -1;var FALSE = 0;function
Expression(theForm,theExpression,Places,Prepend) {places = Places;prepend
=
Prepend;progIndex = 0;prog = theExpression;oForm =
theForm;get_token();if(!token) {serror(2);}Level1();}function Level1(){var
slot;var ttok_type;var temp_token;var result = 0.0;if(tok_type ==
VARIABLE)
{temp_token = token;ttok_type = tok_type;if(typeof oForm[token] !=
"undefined" ) {slot = oForm[token];}else{serror(3);}get_token();if(token
!=
'=') {putback();token = temp_token;tok_type =
ttok_type;}else{get_token();result = Level2();slot.value =
round(result,places);return;}}result=Level2();return result;}function
Level2(){var op = '';var hold = 0;var result = 0;result=Level3();while((op
=
token) == '+' || op == '-') {get_token();hold=Level3();result =
arith(op,result, hold);}return result;}function Level3(){var op = '';var
hold
= 0;var result = 0.0; result = Level4(); while((op = token) == '*' || op
==
'/') {get_token();hold = Level4();result = arith(op,result, hold);}return
result;}function Level4(){var hold = 0;var result = 0;result =
Level5();if((token) == '^') {get_token();hold = Level4();result =
arith('^',result, hold);}return result;}function Level5(){var op = '';var
result = 0.0;op = 0;if((tok_type==DELIMITER) && token == '+' || token ==
'-')
{op = token;get_token();}result = Level6();if(op)result =
unary(op,result);return result;}function Level6(){var result =
0.0;if((token
== '(') && (tok_type == DELIMITER)) {get_token();result =
Level1();if(token
!= ')') { serror(1);} get_token(); } else { result = primitive(); }return
result;}function primitive(){var slot = 0;var result = 0.0;var sValue =
'';var i = 0;switch(tok_type) {case VARIABLE : if(typeof oForm[token] ==
"undefined") { result = 0.0; } else {switch (oForm[token].tagName) {case
'INPUT' : sValue = '0.0';if (oForm[token].type != 'checkbox' )sValue =
oForm[token].value; else if (oForm[token].checked) sValue =
oForm[token].value; while(sValue.charAt(i) == ' ') ++i;
if(sValue.charAt(i)
== '$') { ++i;}sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue)) {serror(4);}result = parseFloat(sValue); if
(isNaN(result)) result = 0; break;case 'SELECT' : sValue =
oForm[token].options[oForm[token].selectedIndex].value;
while(sValue.charAt(i) == ' ') ++i; if(sValue.charAt(i) == '$') ++i;sValue
=
sValue.substr(i,sValue.length-i); if (!isNumber(sValue)) serror(0);result
=
parseFloat(sValue);if (isNaN(result)) result = 0; break;default:if(
oForm[token].length > 0 ) {for(i=0; i < oForm[token].length; i++)
{if(oForm[token].checked) {sValue =
oForm[token].value;while(sValue.charAt(i) == ' ')
++i;if(sValue.charAt(i)
== '$') ++i; sValue = sValue.substr(i,sValue.length-i);if
(!isNumber(sValue))
serror(4);isNaN(parseFloat(sValue)) ? result += 0 : result +=
parseFloat(sValue); var sType = oForm[token].type.toLowerCase(); sType
=
sType.toLowerCase();if (sType == 'radio')
break;}}}break;}}get_token();return
result;case NUMBER:result = parseFloat(token);get_token();return
result;default:return result;}}
function arith(o,r,h){var t = 0.0;var ex = 0.0; switch(o) { case '-':r =
r -
h; break;case '+': r = r + h; break;case '*': r = r * h;break;case '/':r =
r
/ h;break;case '%':t = ((r) / (h));r = r - (t*(h));break;case '^':ex =
r;if(h==0) { r = 1.0;break;}for(t=h-1; t>0; --t) r = (r) * ex;
break;}return
r;}function unary(o, r){if(o=='-') r = -(r);return r;}function
putback(){var
t = '';t = token;for(;t;t++) progIndex--;}function find_var(s){var temp =
'';temp = oForm.s.value;if( temp == '' ) {return(0.0);}return
parseFloat(temp);}function serror(error){var e = new Array;e[0] = "Syntax
error";e[1] = "Unbalanced parentheses";e[2] = "no expression
present";e[3]
= "Form field does not exist " + token;e[4] = "Not a
number";alert(e[error]
+ ' - ' + token);}function get_token(){var temp = '';tok_type =
0;while(prog.charAt(progIndex) == ' ')
++progIndex;if(is_in(prog.charAt(progIndex), "+-*/%^=()")) {tok_type =
DELIMITER;temp += prog.charAt(progIndex++);} else
if(isAlpha(prog.charAt(progIndex)) || prog.charAt(progIndex) == '$') {
while(!isdelim(prog.charAt(progIndex))) temp +=
prog.charAt(progIndex++);tok_type = VARIABLE;} else if
(isDigit(prog.charAt(progIndex)) || prog.charAt(progIndex) == '.')
{while(!isdelim(prog.charAt(progIndex)))temp +=
prog.charAt(progIndex++);tok_type = NUMBER;}token = temp;}function
isdelim(c){if(is_in(c, "+-/*%^=() ") || c=='\t' || c=='\r')return 1;
return
0;}function isAlpha(c) {var sAlpha =
'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';if
(is_in(c,sAlpha))
return 1; else return 0;}function isDigit(c) {var Digits = '0123456789';
if
(is_in(c,Digits)) return 1; else return 0; }function isNumber(s) {var dec
=
0;var i = 0;if(s.charAt(i) == '-' || s.charAt(i) == '+') ++i;for(i;
i<s.length; i++) { if(!isDigit(s.charAt(i))) {if (s.charAt(i) != '.' ||
dec )
return 0; else ++dec; }}return 1;}function is_in(ch,s){if(s.indexOf(ch)
return 1; else return 0;}function round(number,places) {number =
Math.round(number*Math.pow(10,places))/Math.pow(10,places);number +=
'';var x
= number.lastIndexOf('.'); if (x == -1 && places > 0) { number += '.'; x =
number.length -1; }for ( i = ((number.length-1) - x); i < places; i++)
number
+= '0'; return prepend ? '$' + number : number;}
</script>
</head>

<body background="images/Webbkgnd.jpg">

<p>
<b><font face="CG Omega">
<img border="0" src="images/2003-2005logocolor.gif" width="250"
height="215"><br>
2005 International Convention<br>
Orlando, Florida</font></b></p>

<p>
<i><b><font face="CG Omega" color="#CC00FF">TAB to advance to the next
field
and
calculate subtotals/totals</font></b></i></p>
<form method="POST" action="--WEBBOT-SELF--">
<!--webbot bot="SaveResults" u-file="../_private/form_results.htm"
s-format="HTML/BR" s-label-fields="TRUE" b-reverse-chronology="FALSE"
s-email-format="HTML/BR" b-email-label-fields="TRUE"
b-email-replyto-from-field="FALSE" s-email-replyto="2005 International
Convention Registration" b-email-subject-from-field="FALSE"
s-email-subject="2005 International Convention Registration"
s-builtin-fields
s-email-address="(e-mail address removed)" startspan --><input
TYPE="hidden" NAME="VTI-GROUP" VALUE="0"><!--webbot bot="SaveResults"
endspan
i-checksum="43374" --><hr>
<p><b><font face="CG Omega">1. MEMBER INFORMATION</font></b></p>
<p><font face="CG Omega"><b>Full name: <br>
<input type="text" name="REGISTRANT_Name" size="40"> </b></font> </p>
<p><font face="CG Omega"><b>5-Digit Member ID#:<input type="text"
name="REGISTRANT_ID" size="5"></b></font></p>
<p><font face="CG Omega"><b>State/Province/Nation & Chapter:<br>
<input type="text" name="REGISTRANT_SPN_Chapter"
size="40"></b></font></p>
<p><font face="CG Omega"><b>Address:<br>
<input type="text" name="REGISTRANT_Street_Address"
size="50"></b></font></p>
<p><font face="CG Omega"><b>City, S/P/N, Zip/PC:<br>
<input type="text" name="REGISTRANT_City_SPN_Zip"
size="20"></b></font></p>
<p><font face="CG Omega"><b>First name to appear on badge:<br>
<input type="text" name="REGISTRANT_BadgeName"
size="20"> said:
<p><font face="CG Omega"><b>Daytime Phone:<br>
<input type="text" name="REGISTRANT_phone" size="30"></b></font></p>
<p><font face="CG Omega"><b>E-mail Address:<br>
<input type="text" name="REGISTRANT_email" size="40"></b></font></p>
<p><font face="CG Omega"><b>I am actively employed/engaged in
education:<br>
<input type="radio" value="Yes" name="REGISTRANT_EEinEducation">Yes
<input type="radio" name="REGISTRANT_EEinEducation"
value="No">No</b></font></p>
<hr>
<p><b><font face="CG Omega">2. EMERGENCY CONTACT (NOT Attending
Convention)</font></b></p>
<p><font face="CG Omega"><b>Name: <input type="text"
name="EMERGENCY_CONTACT_Name" size="40"></b></font></p>
<p><font face="CG Omega"><b>Phone: <input type="text"
name="EMERGENCY_CONTACT_phone" size="30"></b></font></p>
<hr>
<p><b><font face="CG Omega">3. CONVENTION REGISTRATION</font></b></p>
<p><b><font face="CG Omega">Pre-registration Policy: To be considered
pre-registered, your
registration must be received by Friday, June 17. After this date, all
registrations and changes must be processed at the Convention
Registration
Desk during the Convention.</font></b></p>
<blockquote>
<p><b><font face="CG Omega">A. Member Registration (Includes EDUCATIONAL
SYMPOSIUM, Name Badge,
Convention Registration Packet, Business Sessions, Speakers, Regional
Luncheon
and Reception, Banquet and Favor.)</font></b></p>
<p><font face="CG Omega"><b>Banquet Choice:<br>
<input type="radio" name="REGISTRANT_BanquetChoice" value="Beef">Beef
<input type="radio" name="REGISTRANT_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="REGISTRANT_BanquetChoice"
value="Vegetarian">Vegetarian</b></font></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>TOTAL<br>
<input type="checkbox" name="MEMBER_CONVENTION_REGISTRATION" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'MEMBER_CONVENTION_REGISTRATION=MEMBER_CONVENTION_REGIS
TRATION*100+85',2,0);">Convention
Registration submitted by May 1:
$185 </b></font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">B. Educational Symposium ONLY -
Wednesday, July 6</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>TOTAL<br>
<input type="checkbox" name="EDUCATIONAL_SYMPOSIUM_REGISTRATION"
value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'EDUCATIONAL_SYMPOSIUM_REGISTRATION=EDUCATIONAL_SYMPOSI
UM_REGISTRATION*45+40',2,0);">Educational
Symposium Registration submitted by May 1:
$85</b></font></p>
<blockquote>
<blockquote>
<p><b><font face="CG Omega">Professional Growth/Fraternity Education
Breakout Session Choices</font></b></p>
<ul>
<li><b><font face="CG Omega"><a target="_blank"
href="Breakout.htm">Click here for session titles
and descriptions.</a></font></b></li>
</ul>
<p><font face="CG Omega"><b>Fill in session numbers, indicating your
first, second and third choices
for each July 6 time slot.<br>
July 6; 11:15 AM-12:15 PM<br>
(Sessions 1-19):<br>
First Choice #<input type="text" name="ES_FIRST_MORNING_SESSION_CHOICE"
size="2">
<br>
Second Choice#<input type="text" name="ES_SECOND_MORNING_SESSION_CHOICE"
size="2">
<br>
Third Choice#<input type="text" name="ES_THIRD_MORNING_SESSION_CHOICE"
size="2"><br>
July 6; 2:45-3:45 PM<br>
(Sessions 20-38):<br>
First Choice #<input type="text" name="ES_FIRST_AFTERNOON_SESSION_CHOICE"
size="2">
<br>
Second Choice#<input type="text"
name="ES_SECOND_AFTERNOON_SESSION_CHOICE"
size="2">
<br>
Third Choice#<input type="text" name="ES_THIRD_AFTERNOON_SESSION_CHOICE"
size="2"></b></font></p>
</blockquote>
</blockquote>
<p align="right"><font face="CG Omega"><b>SESSION 39, Tuesday, July 5,
includes transportation,
<input type="text" name="QTY_SESSION_39" size="2"> at $20
each:
<input type="text" name="SESSION_39_TOTAL" size="7"
onblur="Expression(this.form,'SESSION_39_TOTAL=QTY_SESSION_39*20',2,1);"><br
SESSION 40, Monday, July 11, includes transportation,
<input type="text" name="QTY_SESSION_40" size="2"> at $20 each:
<input type="text" name="SESSION_40_TOTAL" size="7"
onblur="Expression(this.form,'SESSION_40_TOTAL=QTY_SESSION_40*20',2,1);"></b
<blockquote>
<p align="left"><b><font face="CG Omega">C. Optional Special Function
Fees:</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>
<input type="checkbox" name="PAST_SPN_PRESIDENTS_LUNCHEON" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'PAST_SPN_PRESIDENTS_LUNCHEON=PAST_SPN_PRESIDENTS_LUNCH
EON*20+5',2,0);">Past
S/P/N Presidents' Luncheon (Past S/P/N Presidents only):
$25<br>
<input type="checkbox" name="LITTLE_WIGS_BREAKFAST" value="1"
onclick="if(!this.checked) {this.value=0};
Expression(this.form,'LITTLE_WIGS_BREAKFAST=LITTLE_WIGS_BREAKFAST*10+10',2,0
);">Little
Wigs Breakfast (Past International Chapter Members): $20</b></font></p>
<blockquote>
<p align="left"><b><font face="CG Omega">D. NONMEMBER GUEST TICKETS<br>
Please specify how many tickets you are purchasing for each
event.</font></b></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>Banquet Guest(s) (Not included
in
Alpha Delta Kappa Association Registration Fee),
<input type="text" name="QTY_BANQUET_GUEST" size="2"> at $55 each:
<input type="text" name="BANQUET_GUEST_TOTAL" size="7"
onblur="Expression(this.form,'BANQUET_GUEST_TOTAL=QTY_BANQUET_GUEST*55',2,1)
;"> said:
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<blockquote>
<p align="left"><font face="CG Omega"><b>Banquet Choice:<br>
<input type="radio" name="GUEST1_BanquetChoice" value="Beef">Beef
<input type="radio" name="GUEST1_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="GUEST1_BanquetChoice"
value="Vegetarian">Vegetarian<br>
<input type="radio" name="GUEST2_BanquetChoice" value="Beef">Beef
<input type="radio" name="GUEST2_BanquetChoice" value="Salmon">Salmon
<input type="radio" name="GUEST2_BanquetChoice"
value="Vegetarian">Vegetarian</b></font></p>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
</blockquote>
<p align="right">
<font face="CG Omega"><b>
Regional
Luncheon Guest(s),
<input type="text" name="QTY_REGIONAL_LUNCHEON_GUESTS" size="2"> at $30
each:
<input type="text" name="REGIONAL_LUNCHEON_GUEST_TOTAL" size="7"
onblur="Expression(this.form,'REGIONAL_LUNCHEON_GUEST_TOTAL=QTY_REGIONAL_LUN
CHEON_GUESTS*30' said:
<p align="right"><b><font face="CG Omega">E. ALPHA DELTA KAPPA ASSOC. FOR
MEN CONVENTION
REGISTRATION(S)</font></b><font face="CG Omega"><b> <input
type="text" name="QTY_ADKA_REGISTRATIONS" size="2">
at $40 each:
<input type="text" name="ADKA_REGISTRATION_TOTAL" size="7"
onblur="Expression(this.form,'ADKA_REGISTRATION_TOTAL=QTY_ADKA_REGISTRATIONS
*40' said:
face="CG Omega"><br>
(Includes Annual Dues, Alpha Delta Kappa Association Breakfast, Reception
and
General Session Speakers. Does not include Banquet. Alpha Delta
Kappa Association tickets may be purchased above for the Banquet and/or
the
Regional Luncheon.)</font></b></p>
<blockquote>
<blockquote>
<p align="left"><font face="CG Omega"><b>Name to appear on badge:
<input type="text" name="ADKA_BADGE_NAME" size="40"><br>
</b></font></p>
</blockquote>
</blockquote>
<p align="right"><font face="CG Omega"><b>Alpha Delta Kappa Association
Membership Dues for Alpha Delta Kappa Association members <br>
NOT ATTENDING CONVENTION, <input type="text" name="QTY_ADKA_DUES"
size="2"> at $6
each:
<input type="text" name="ADKA_DUES_TOTAL" size="3"
onblur="Expression(this.form said:
<blockquote>
<p align="right"><font face="CG Omega"><b>Alpha Delta Kappa Association
member name:<br>
<input type="text" name="ADKA_MEMBER_NAME" size="40"></b></font></p>
</blockquote>
<p align="right"><font face="CG Omega"><b>F. 2005 International
Convention
charm and/or pin: charm(s),
<input type="text" name="QTY_CHARMS" size="2"> at $5 each:
<input type="text" name="CHARM_TOTAL" size="7"
onblur="Expression(this.form,'CHARM_TOTAL=QTY_CHARMS*5',2,1);"><br>
pin(s), <input type="text" name="QTY_PINS" size="2"> at $5 each:
<input type="text" name="PIN_TOTAL" size="7"
onblur="Expression(this.form said:
<p align="right"><font face="CG Omega"><b>TOTAL FEE in U.S. FUNDS: (Add
registration, special
functions, guests' tickets and pin/charm)
<input type="text" name="TOTAL_FEE_TO_BE_CHARGED" size="7"
onblur="Expression(this.form,'TOTAL_FEE_TO_BE_CHARGED=MEMBER_CONVENTION_REGI
STRATION+EDUCATIONAL_SYMPOSIUM_REGISTRATION+SESSION_39_TOTAL+SESSION_40_TOTA
L+PAST_SPN_PRESIDENTS_LUNCHEON+LITTLE_WIGS_BREAKFAST+BANQUET_GUEST_TOTAL+REG
IONAL_LUNCHEON_GUEST_TOTAL+ADKA_REGISTRATION_TOTAL+ADKA_DUES_TOTAL+CHARM_TOT
AL+PIN_TOTAL' said:
<p align="left"><b><font face="CG Omega">CANCELLATION POLICY:
Cancellations must be received in writing
by June 17, 2005 to qualify for a refund.</font></b></p>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top