473,325 Members | 2,860 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,325 software developers and data experts.

Urgent...Having problem debugging...Need help ASAP!

7
Hello,
To start with here is the code:

Expand|Select|Wrap|Line Numbers
  1. Public Function Paymentget (s12MoRate)
  2. strCompanyCode = objXML.selectSingleNode("policy/companyCode").text
  3. strState = objXML.selectSingleNode("policy/insured/state").text
  4.  
  5. set rsDownPayment = getCache("down_payment")
  6.  
  7. dim tempPremium, totalTaxes
  8.  
  9. totalTaxes = 0
  10. tempPremium = s12MoRate
  11.  
  12. ' calculate the taxes so they can be front loaded in the payment schedule
  13. dim TaxCov
  14. for each TaxCov in objXml.selectNodes("//coverage[manOptSwitch='T']")
  15. taxRate = cdbl(TaxCov.selectSingleNode("../rate/coverage[@covCode = '" & TaxCov.selectSingleNode("coverageCode").text & "']/twelveMonth").text)
  16. tempPremium = tempPremium - taxRate
  17. totalTaxes = totalTaxes + taxRate
  18. next
  19.  
  20. ' CLR - new filter as of 12/25/02 for new payplan table structure
  21. set rsDownPayment = applyFilterAndReloadRecordset(rsDownPayment, "a01_company = '" & objLogic.Company & "' or a01_company = '99'")
  22. set rsDownPayment = applyFilterAndReloadRecordset(rsDownPayment, "a02_state = '" & objLogic.BikeState & "' or a02_state = 'ZZ'")
  23. set rsDownPayment = applyFilterAndReloadRecordset(rsDownPayment, "min_premium <= " & tempPremium & " and b80_userline = '" & objLogic.userline & "' and profile = '" & objLogic.profile & "'")
  24.  
  25. dim minimumPct
  26. dim payment
  27. dim installmentfee
  28.  
  29. ' initialize payment percentage, amount, and fee to be full pay parameters as default
  30. minimumPct = 1
  31. payment = tempPremium
  32. installmentfee = 0
  33. ' now loop through available plans, and get the minimum that they can get in the policy
  34. while not rsDownPayment.eof
  35.  
  36. if cdbl(rsDownPayment("m84_instpct")) < cdbl(minimumPct) then
  37.  
  38. minimumPct = cdbl(rsDownPayment("m84_instpct"))
  39. payment = cdbl(rsDownPayment("m84_instpct")) * tempPremium
  40. installmentfee = rsDownPayment("first_installment_fee")
  41.  
  42. end if
  43. rsDownPayment.MoveNext
  44. wend
  45.  
  46. Paymentget = cdbl(payment) + cdbl(installmentFee) + cdbl(totalTaxes)
  47.  
  48. End Function
  49.  
  50.  
  51. I have a few questions for the asp guru’s out there:
  52. Just a brief summary…this function works fine until the value of s12MoRate is less than 999. If it is more than 999 than the value for the Payment (s12MoRate) is 0, which is not right. 
  53. I am not good at asp & was wondering on how to debug the application starting from checking what value does s12MoRate has?? 
  54. Than how do I check the value for the following?
  55. set rsDownPayment = applyFilterAndReloadRecordset(rsDownPayment, "a01_company = '" & objLogic.Company & "' or a01_company = '99'")
  56. set rsDownPayment = applyFilterAndReloadRecordset(rsDownPayment, "a02_state = '" & objLogic.BikeState & "' or a02_state = 'ZZ'")
  57. set rsDownPayment = applyFilterAndReloadRecordset(rsDownPayment, "min_premium <= " & tempPremium & " and b80_userline = '" & objLogic.userline & "' and profile = '" & objLogic.profile & "'")
  58. Than check does the while loop execute and what value does payment gets (payment = cdbl(rsDownPayment("m84_instpct")) * tempPremium)??
  59.  
Please wrap your code in CODE tags theres a sticky on how todo it

Mod iam_clint

Any help is appreciated ASAP…thanks a lot for yr time…bye
Jan 9 '07 #1
0 1127

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Rahul S. | last post by:
Hey all: I need urgent information how to set the environment in Visual.NET wiritng in C. I am working with a licensed version of the Analyze 6.0 software from mayo clinic. I need to write...
3
by: Rahul S. | last post by:
Hey all: I need urgent information how to set the environment in Visual.NET wiritng in C. I am working with a licensed version of the Analyze 6.0 software from mayo clinic. I need to write...
7
by: Gordon Smith | last post by:
I have four (4) ASP.NET Web applications/Web sites on a IIS/6 - Windows Server 2003 production server. 3 of them work fine. I just installed the 4th one and it's Application_Start event is not...
8
by: Chris | last post by:
Hi, All my websites and webservices are down. I get the following message Server Error in '/mywebservices' Application....
0
by: Radhesh Reddy | last post by:
One of our clients is in need of following consultants Business analyst with I2 background Location: Overland park,KS Duration: 6 months+ startdate: ASAP Description and Skills We are...
4
by: archana | last post by:
Hi all, I am having one confusion regarding invoking web method of web service asychronously through windows applicaiton. What i am doing is i am having one long runing web method whose one...
0
by: IT Jobs | last post by:
Hi We are from Ventures IT Solutions, A Young Organisation based in Delhi, and is started with a vision to provide, quality services to our esteemed clients and candidates, We have some...
2
by: feltra | last post by:
Hi, The following is from my friend, who has some technical problem at present in accessing the web... I am writing for him... Kindly request your inputs ASAP, as he has some kind of deadline...
3
by: JMD | last post by:
A set of xsd files has been working fine for us at this site, but now it gives *intermittent* errors for someone at a different cite (who is consuming the code we are producing). Most of the time...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.