S
sarel
Hi,
I need to refresh an IFRAME in my asp page, currently I use a popup
screen to do the calculation, but want to add an IFRAME in the page.
Here is the code that I currently use.
<SCRIPT Language="VBScript">
Function CalcPremium()
If document.Pers_Info.txtCalcPremium.Value = "True" or
document.Pers_Info.txtAutoCalcUser.Value = "True" Then
strWindow = "Rates/AllRisk.asp?Area='" &
document.Pers_Info.txtPostal_Code.Value & "'"
If document.Pers_Info.txtSum_Insured.Value > "0" Then
strWindow = strWindow & "&Sum_Insured=" &
(document.Pers_Info.txtSum_Insured.Value)
Else
strWindow = strWindow & "&Sum_Insured=0.5"
End if
strWindow = strWindow & "&NCB='" & document.Pers_Info.cboNCB.Value
& "'"
strWindow = strWindow & "&Type=" & document.Pers_Info.cboType.Value
& ""
strWindow = strWindow & "&Include10Discount=5"
If document.Pers_Info.txtDiscounts.Value > "0" Then
strWindow = strWindow & "&Discounts=" &
document.Pers_Info.txtDiscounts.Value
Else
strWindow = strWindow & "&Discounts=0"
End if
If document.Pers_Info.txtLoadings.Value > "0" Then
strWindow = strWindow & "&Loadings=" &
document.Pers_Info.txtLoadings.Value
Else
strWindow = strWindow & "&Loadings=0"
END IF
strWindow = strWindow & "&CalcDate=" &
document.Pers_Info.txtCalcDate.Value
strWindow = strWindow & "&AutoCalcUser=" &
document.Pers_Info.txtAutoCalcUser.Value
strWindow = strWindow & "&AutoPremium=" &
document.Pers_Info.txtPremium.Value
strWindow = strWindow & "&txtCalcPrm2=" &
document.Pers_Info.txtCalcPrm2.Value
strWindow = strWindow & "&Debug=0"
window.open strWindow, "CalcPrem", "width=1, height=1, top=0,
left=0"
CalcPremium = 0
Else
CalcPremium = 0
End If
END Function
</SCRIPT>
Instead on opening a popup I want to parse strwindow's value to the
IFRAME to open the new page.
All your help will be apreciated.
I need to refresh an IFRAME in my asp page, currently I use a popup
screen to do the calculation, but want to add an IFRAME in the page.
Here is the code that I currently use.
<SCRIPT Language="VBScript">
Function CalcPremium()
If document.Pers_Info.txtCalcPremium.Value = "True" or
document.Pers_Info.txtAutoCalcUser.Value = "True" Then
strWindow = "Rates/AllRisk.asp?Area='" &
document.Pers_Info.txtPostal_Code.Value & "'"
If document.Pers_Info.txtSum_Insured.Value > "0" Then
strWindow = strWindow & "&Sum_Insured=" &
(document.Pers_Info.txtSum_Insured.Value)
Else
strWindow = strWindow & "&Sum_Insured=0.5"
End if
strWindow = strWindow & "&NCB='" & document.Pers_Info.cboNCB.Value
& "'"
strWindow = strWindow & "&Type=" & document.Pers_Info.cboType.Value
& ""
strWindow = strWindow & "&Include10Discount=5"
If document.Pers_Info.txtDiscounts.Value > "0" Then
strWindow = strWindow & "&Discounts=" &
document.Pers_Info.txtDiscounts.Value
Else
strWindow = strWindow & "&Discounts=0"
End if
If document.Pers_Info.txtLoadings.Value > "0" Then
strWindow = strWindow & "&Loadings=" &
document.Pers_Info.txtLoadings.Value
Else
strWindow = strWindow & "&Loadings=0"
END IF
strWindow = strWindow & "&CalcDate=" &
document.Pers_Info.txtCalcDate.Value
strWindow = strWindow & "&AutoCalcUser=" &
document.Pers_Info.txtAutoCalcUser.Value
strWindow = strWindow & "&AutoPremium=" &
document.Pers_Info.txtPremium.Value
strWindow = strWindow & "&txtCalcPrm2=" &
document.Pers_Info.txtCalcPrm2.Value
strWindow = strWindow & "&Debug=0"
window.open strWindow, "CalcPrem", "width=1, height=1, top=0,
left=0"
CalcPremium = 0
Else
CalcPremium = 0
End If
END Function
</SCRIPT>
Instead on opening a popup I want to parse strwindow's value to the
IFRAME to open the new page.
All your help will be apreciated.