bikebanditcom
Programmer
below is a very extensive if...then statement i just finished, and it seems to be valid but i'm not getting any calculations, i'm writing every form field to the screen on my page that processes the form and inserts it into the database, the problem is the three fields that are in the calc are restockingFee, transAmount, and transType, those three are not being written to the screen meaning they aren't working. my code seems to be proper, can anyone help?
<%
If Complete = "Yes" Then
If california = "Yes" Then
If shipped = " Yes" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition One
restockingFee = mercValue * .2
transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax - restockingFee
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Two - theroretically can't happen i think
restockingFee = 0
Cdbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax)
transType = "Enter Credit"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Three - must be a bb error
restockingFee = 0
Cdbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Four - must be an exchange
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
ElseIf shipped = "No" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Five - therorectially can't happen i think
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Six
restockingFee = 0
Cdbl(transAmount = mercValue * -.2)
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Seven - therorectially can't happen i think
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Eight - could only be a cancel within 1 hr
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
End If
ElseIf california = "No" Then
If shipped = " Yes" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Nine
CDbl(restockingFee = mercValue * .2)
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping - restockingFee)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Ten - theroretically can't happen i think
restockingFee = 0
Cdbl(transAmount = mercValue + addOrigShipping + addRtrnShipping)
transType = "Enter Credit"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Eleven - must be a bb error
restockingFee = 0
Cdbl(transAmount = mercValue + addOrigShipping + addRtrnShipping)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Twelve - must be an exchange
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
ElseIf shipped = "No" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Thirteen - therorectially can't happen i think
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Fourteen
restockingFee = 0
Cdbl(transAmount = mercValue * -.2)
transType = "Enter Charge"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Fifteen - therorectially can't happen i think
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Sixteen- could only be a cancel within 1 hr
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
End If
End If
ElseIf complete = "No" Then
If california = "Yes" Then
If shipped = " Yes" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition One
CDbl(restockingFee = mercValue * .2)
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Two
CDbl(restockingFee = mercValue * .2)
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax - restockingFee)
transType = "Enter Credit"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Three
restockingFee = 0
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Four - must be an exchange only i think
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
ElseIf shipped = "No" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Five - not possible i think
ElseIf CrdtToBeIssd = "No" Then
'Condition Six
CDbl(restockingFee = mercValue * -.2)
CDbl(transAmount = restockingFee)
TransType = "Enter Charge"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Seven - not possible
restockingFee = 0
transAmount = 0
transType = 0
ElseIf CrdtToBeIssd = "No" Then
'Condition Eight - not possible
restockingFee = 0
transAmount = 0
transType = 0
End If
End If
End If
ElseIf california = "No" Then
If shipped = " Yes" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Nine
CDbl(restockingFee = mercValue * .2)
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping - restockingFee)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Ten
CDbl(restockingFee = mercValue * -.2)
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + restockingFee)
transType = "Enter Credit"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Eleven - not possible
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Twelve - could only an exchange
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
ElseIf shipped = "No" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Thirteen - no possible
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Fourteen - could only be a cancel outside 1 hr
CDbl(restockingFee = mercValue * -.2)
CDbl(transAmount = restockingFee)
transType = "Enter Charge"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Fifteen - not possible
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Sixteen
CDbl(restockingFee = 0)
CDbl(transAmount = 0)
End If
End If
End If
End If
End If
%>
<%
If Complete = "Yes" Then
If california = "Yes" Then
If shipped = " Yes" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition One
restockingFee = mercValue * .2
transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax - restockingFee
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Two - theroretically can't happen i think
restockingFee = 0
Cdbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax)
transType = "Enter Credit"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Three - must be a bb error
restockingFee = 0
Cdbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Four - must be an exchange
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
ElseIf shipped = "No" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Five - therorectially can't happen i think
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Six
restockingFee = 0
Cdbl(transAmount = mercValue * -.2)
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Seven - therorectially can't happen i think
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Eight - could only be a cancel within 1 hr
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
End If
ElseIf california = "No" Then
If shipped = " Yes" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Nine
CDbl(restockingFee = mercValue * .2)
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping - restockingFee)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Ten - theroretically can't happen i think
restockingFee = 0
Cdbl(transAmount = mercValue + addOrigShipping + addRtrnShipping)
transType = "Enter Credit"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Eleven - must be a bb error
restockingFee = 0
Cdbl(transAmount = mercValue + addOrigShipping + addRtrnShipping)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Twelve - must be an exchange
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
ElseIf shipped = "No" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Thirteen - therorectially can't happen i think
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Fourteen
restockingFee = 0
Cdbl(transAmount = mercValue * -.2)
transType = "Enter Charge"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Fifteen - therorectially can't happen i think
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Sixteen- could only be a cancel within 1 hr
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
End If
End If
ElseIf complete = "No" Then
If california = "Yes" Then
If shipped = " Yes" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition One
CDbl(restockingFee = mercValue * .2)
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Two
CDbl(restockingFee = mercValue * .2)
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax - restockingFee)
transType = "Enter Credit"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Three
restockingFee = 0
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + caSalesTax)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Four - must be an exchange only i think
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
ElseIf shipped = "No" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Five - not possible i think
ElseIf CrdtToBeIssd = "No" Then
'Condition Six
CDbl(restockingFee = mercValue * -.2)
CDbl(transAmount = restockingFee)
TransType = "Enter Charge"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Seven - not possible
restockingFee = 0
transAmount = 0
transType = 0
ElseIf CrdtToBeIssd = "No" Then
'Condition Eight - not possible
restockingFee = 0
transAmount = 0
transType = 0
End If
End If
End If
ElseIf california = "No" Then
If shipped = " Yes" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Nine
CDbl(restockingFee = mercValue * .2)
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping - restockingFee)
transType = "Enter Credit"
ElseIf CrdtToBeIssd = "No" Then
'Condition Ten
CDbl(restockingFee = mercValue * -.2)
CDbl(transAmount = mercValue + addOrigShipping + addRtrnShipping + restockingFee)
transType = "Enter Credit"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Eleven - not possible
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Twelve - could only an exchange
restockingFee = 0
transAmount = 0
transType = "No Transaction"
End If
End If
ElseIf shipped = "No" Then
If restockingFee = "Yes" Then
If CrdtToBeIssd = "Yes" Then
'Condition Thirteen - no possible
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Fourteen - could only be a cancel outside 1 hr
CDbl(restockingFee = mercValue * -.2)
CDbl(transAmount = restockingFee)
transType = "Enter Charge"
End If
ElseIf restockingFee = "No" Then
If CrdtToBeIssd = "Yes" Then
'Condition Fifteen - not possible
restockingFee = 0
transAmount = 0
transType = "No Transaction"
ElseIf CrdtToBeIssd = "No" Then
'Condition Sixteen
CDbl(restockingFee = 0)
CDbl(transAmount = 0)
End If
End If
End If
End If
End If
%>