+ Reply to Thread
Results 1 to 3 of 3

How to change parts of the formula

  1. #1
    Registered User
    Join Date
    11-13-2009
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    3

    How to change parts of the formula

    How to use VBA codes to automatically change parts of the formula?

    Example1:
    Change formula "=SUM(A$10:A$100)" into "=SUM(A$10:A$1000)";

    Example2:
    Chage formula
    "=IF(YEAR('H:\Work\RCIP\[09RCIP__Input.xlsx]PCAInput'!$E10)<Partnership_Year, MAX(0, 'H:\Work\RCIP\[09RCIP__Input.xlsx]PCAInput'!$Q10), MAX(PCA!H10,0)"
    into
    "=IF(YEAR('H:\Work\ABC\[09ABC__Input.xlsx]PCAInput'!$E10)<Partnership_Year, MAX(0, 'H:\Work\ABC\[09ABC__Input.xlsx]PCAInput'!$Q10), MAX(PCA!H10,0)".

    Thanks a lot!
    Last edited by meetwell; 11-16-2009 at 02:13 PM.
    Z

  2. #2
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,330

    Re: How to change parts of the formula

    Hi meetwell
    what do you mean by automatically change code?

    You could use the VBA find/replace tool
    or set variables
    eg
    Please Login or Register  to view this content.
    hope it helps
    If the solution helped please donate to RSPCA

    Site worth visiting: Rabbitohs

  3. #3
    Registered User
    Join Date
    11-13-2009
    Location
    New York
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: How to change parts of the formula

    Thanks, pike.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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