+ Reply to Thread
Results 1 to 7 of 7

Replace with IF function

  1. #1
    Registered User
    Join Date
    05-24-2016
    Location
    Tampa, Florida
    MS-Off Ver
    2016
    Posts
    14

    Replace with IF function

    Hey Guys! I have attached the workbook that I am working on for reference. I have two worksheets in this workbook to keep basketball stats. One worksheet is called Game (Sheet 1) and the other is called Game Records (Sheet 2). On Sheet 1, as I complete each game I will manually input those figures (minutes, fgs, 3pt fgs, etc). For example if my minutes played in a basketball were 50 then that will go under the Game row, column Minutes played. What I want to do is write a formula (for minutes played) in Sheet 2 that takes that value (50) and says IF that value is greater then the value in x cell then use that value if not, use x cell. You can see in Sheet 2 that cell B24 has that formula. The problem is it's reference cell, B:33 (which I will be hiding) has to be manually updated. So I want B:33 to read the minutes played (for a game) in sheet 1 and if that value is greater then the value that is currently in B:33 then replace it. Problem is, I keep running into circular references (rightfully so), can anyone help me with this? Thanks!
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    10-09-2012
    Location
    Dallas, Texas
    MS-Off Ver
    MO 2010 & 2013
    Posts
    3,049

    Re: Replace with IF function

    it sounds like you just want the MAX of the two, in which case you can use for cell B24:
    Please Login or Register  to view this content.
    Please ensure you mark your thread as Solved once it is. Click here to see how.
    If a post helps, please don't forget to add to our reputation by clicking the star icon in the bottom left-hand corner of a post.

  3. #3
    Registered User
    Join Date
    05-24-2016
    Location
    Tampa, Florida
    MS-Off Ver
    2016
    Posts
    14
    Quote Originally Posted by mikeTRON View Post
    it sounds like you just want the MAX of the two, in which case you can use for cell B24:
    Please Login or Register  to view this content.
    Thanks for your reply! The MAX function still requires me to manually enter a value into B33. Im not sure of any way around that though. What im trying to accomplish is, a formula that reads the stat cells on sheet 1 and inputs them into the game records tab. If the stats on sheet 1 exceed those on sheet 2 then replace. But i only want to manually enter the sheet 1 values. The sheet 2 values should be replaced (via a formula) once the sheet 1 values exceed them.

  4. #4
    Forum Expert
    Join Date
    10-09-2012
    Location
    Dallas, Texas
    MS-Off Ver
    MO 2010 & 2013
    Posts
    3,049

    Re: Replace with IF function

    I guess I still dont understand your sample. I suggest providing sample examples in there as well, with real data and a hand typed "solution" so we can see what you are trying to do.

  5. #5
    Registered User
    Join Date
    05-24-2016
    Location
    Tampa, Florida
    MS-Off Ver
    2016
    Posts
    14

    Re: Replace with IF function

    I've reattached the workbook for reference. You'll see on the Game worksheet (Sheet 1) that I have filled in minutes calculations (12 per quarter and 5 for overtime) totaling 53 minutes which calculates on Sheet 1, Cell B17. I would go ahead and manually input the rest of data on this sheet as mentioned in my original post. Let's say that my first game out I end up playing 53 minutes. That value would be copied from the Game page to the Game Records page (as you see in the workbook). If I then play a second game (all of my Sheet 1 values are erased so I can start a new game) and I exceed 53 minutes, I want the new greater value to replace the old 53 value, and so on and so on. The MAX function would work IF I manually entered the new personal record which exceeds 53 minutes but I'd like for excel to take the initial 53 minutes from the first game then compare that value to my second game and if the second game exceeds the first then replace. Like keep a personal record book of sorts.
    Attached Files Attached Files

  6. #6
    Forum Expert
    Join Date
    10-09-2012
    Location
    Dallas, Texas
    MS-Off Ver
    MO 2010 & 2013
    Posts
    3,049

    Re: Replace with IF function

    Formulas can't replace raw data.

    It sounds like you need a THIRD sheet that is just a report to show the max and such. Otherwise what you are trying to do is not possible with formulas.

  7. #7
    Registered User
    Join Date
    05-24-2016
    Location
    Tampa, Florida
    MS-Off Ver
    2016
    Posts
    14
    Quote Originally Posted by mikeTRON View Post
    Formulas can't replace raw data.

    It sounds like you need a THIRD sheet that is just a report to show the max and such. Otherwise what you are trying to do is not possible with formulas.
    Okay, thank you very much!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. REPLACE function help replace two separate texts Ctrl H
    By Uldis in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-23-2015, 10:51 AM
  2. Excel function in VBA using the Replace function
    By starlev in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-18-2015, 06:34 AM
  3. [SOLVED] Need help with REPLACE function to replace HEX A0 with HEX 20 in string
    By flyboy54 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 11-26-2013, 12:52 PM
  4. Replace function
    By intothewild in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-28-2012, 06:44 PM
  5. Sum Function/Replace??
    By Celtic in forum Excel General
    Replies: 2
    Last Post: 10-07-2008, 01:46 PM
  6. Replace Function:Replace" and type in
    By ronnyc in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-19-2007, 06:26 PM
  7. Use of Replace function...
    By OneLgGrsyBear in forum Excel General
    Replies: 2
    Last Post: 08-27-2006, 06:01 PM

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