472,325 Members | 1,020 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

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

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

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
  5. set rsDownPayment = getCache("down_payment")
  7. dim tempPremium, totalTaxes
  9. totalTaxes = 0
  10. tempPremium = s12MoRate
  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
  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 & "'")
  25. dim minimumPct
  26. dim payment
  27. dim installmentfee
  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
  36. if cdbl(rsDownPayment("m84_instpct")) < cdbl(minimumPct) then
  38. minimumPct = cdbl(rsDownPayment("m84_instpct"))
  39. payment = cdbl(rsDownPayment("m84_instpct")) * tempPremium
  40. installmentfee = rsDownPayment("first_installment_fee")
  42. end if
  43. rsDownPayment.MoveNext
  44. wend
  46. Paymentget = cdbl(payment) + cdbl(installmentFee) + cdbl(totalTaxes)
  48. End Function
  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)??
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 1086

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

Similar topics

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...
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...
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...
by: Chris | last post by:
Hi, All my websites and webservices are down. I get the following message Server Error in '/mywebservices' Application....
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+...
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...
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...
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...
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...
by: tammygombez | last post by:
Hey everyone! I've been researching gaming laptops lately, and I must say, they can get pretty expensive. However, I've come across some great...
by: better678 | last post by:
Question: Discuss your understanding of the Java platform. Is the statement "Java is interpreted" correct? Answer: Java is an object-oriented...
by: teenabhardwaj | last post by:
How would one discover a valid source for learning news, comfort, and help for engineering designs? Covering through piles of books takes a lot of...
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge...
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
by: Matthew3360 | last post by:
Hi there. I have been struggling to find out how to use a variable as my location in my header redirect function. Here is my code. ...
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...

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.