Results 1 to 2 of 2

Thread: PMT function

  1. #1

    Thread Starter
    New Member
    Join Date
    Nov 2000
    Posts
    1

    Smile

    I am trying to use the VB Payment function to calculate a loan payment. So far unsuccessful. Here is what I have on my form:
    A textbox named txtAmount, which is the loan amount the user enters
    A combo box named cboTerm, which is the term of the loan 1-10
    Another combo box named cboRate, which is the interest rate 5-15
    A textbox named txtPayment, which displays the answer
    A command button named cmdPayment

    When cmdPayment is clicked, I would like the Monthly Payment to be displayed in the txtPayment textbox.

    A form load procedure, which I have already coded, initally loads the combo box's.
    Can anyone help me with the compute payment command button code?

  2. #2
    Frenzied Member
    Join Date
    Jun 2000
    Location
    East Providence, RI
    Posts
    1,715

    Code:
    inta as single
    intb as single
    
    Private Sub cmdPayment_click()
    inta = txtAmount.text
    intb = cboRate.text /100 * cboTerm.text
    txtpayment.text = inta * inb
    End Sub
    i think that the code above is wrong, because i'm not sure how the rate is measured, and the term and all, but the code should work if i did it all correct
    NXSupport - Your one-stop source for computer help

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width