+ Reply to Thread
Results 1 to 6 of 6

Updates

  1. #1
    Registered User
    Join Date
    01-12-2007
    Posts
    41

    Updates

    hi
    i need a MACRO to get all the month in a A cell when i enter eg: 12/24/36 or any number
    the rent amount in B cell and the balance in c cell
    Attached the sample .zip
    thanxs
    Attached Files Attached Files

  2. #2
    Forum Expert Greg M's Avatar
    Join Date
    08-16-2007
    Location
    Dublin. Ireland
    MS-Off Ver
    Office 2016
    Posts
    4,481
    Hi there,

    Insert the following formula in cell A8 of your sample workbook:
    Please Login or Register  to view this content.
    Insert the following formula in cell B7 of your sample workbook:
    Please Login or Register  to view this content.
    Insert the following formula in cell B8 of your sample workbook:
    Please Login or Register  to view this content.
    Leave the existing formula in cell C8

    Now, insert the following code in the VBA module for "Sheet1" of your sample workbook - it MUST be entered in the worksheet module.
    Please Login or Register  to view this content.
    Now, whenever the value of cell C8 (No of months) changes, the repayments table will be updated automatically.

    Hope this helps,

    Greg M

  3. #3
    Registered User
    Join Date
    01-12-2007
    Posts
    41
    HI
    i think i was not clear i need to get the value from the B2,B3,B4 WHEN I ENTER THE value in these cell i need to get the
    months in cell A , the rent IN CELL B AND BALANCE IN CELL C
    FOR eg:if i enter 12 months in cell B3 it should calulate the balance ,THEN I SHOULD GET 12 RECORDS
    IF 24 MONTHS THEN 24 RECORDS ETC...

  4. #4
    Forum Expert Greg M's Avatar
    Join Date
    08-16-2007
    Location
    Dublin. Ireland
    MS-Off Ver
    Office 2016
    Posts
    4,481
    Hi again,

    In the workbook I posted, I insert a Total Amount of 300,000 in cell B2

    Then, I insert 12 in the Months cell B3, and what happens automatically is that the Rent (25,000) is calculated in cell B4, and the range A7:C18 (12 rows) is filled with the Month Number (1 - 12) in cells A7:A18, the Rent (25,000 each month) in cells B7:B18, and the Balance (reducing from 275,000 to 0) in cells C7:C18.

    If I now insert 24 in the Months cell B3, the Rent (12,500) is calculated in cell B4, and the range A7:C30 (24 rows) is filled with the Month Number (1 - 24) in cells A7:A30, the Rent (12,500 each month) in cells B7:B30, and the Balance (reducing from 287,500 to 0) in cells C7:C30.

    The process is similar if I insert 36 in the months cell.

    I thought that the above was what you required, and your latest post seems to confirm this. Have I misunderstood what you need?

    Regards,

    Greg M

  5. #5
    Registered User
    Join Date
    01-12-2007
    Posts
    41
    hi
    thanxs a lot it worked ....

  6. #6
    Forum Expert Greg M's Avatar
    Join Date
    08-16-2007
    Location
    Dublin. Ireland
    MS-Off Ver
    Office 2016
    Posts
    4,481
    Great! Glad to have helped - thanks for the feedback.

    Regards,

    Greg M

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1