+ Reply to Thread
Results 1 to 9 of 9

Change content of one cell based on content of another

  1. #1
    Registered User
    Join Date
    07-25-2010
    Location
    Toronto, Canada
    MS-Off Ver
    Excel 2003
    Posts
    11

    Change content of one cell based on content of another

    Hello it's been a while since I've had to format a spreadsheet and I am looking for some guidance please.

    I have a Formula tab where I have a column with one value (ie. 1800) and the next column showing another value (ie. 2). What I am trying to achieve is to have the '2' appear in 'S14' (which is on worksheet May 7) when I place 1800 in 'D14' on that worksheet.

    I really hope this makes sense.

    Thank you in advance for your help.

    Flora
    Flora Lina

  2. #2
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,649

    Re: Change content of one cell based on content of another

    It is impossible to provide any help to you unless you provide a sample workbook which is exactly same as your original workbook along with the sample data and the desired output on a different sheet or explaining in the sheet itself that what are you trying to achieve.

    To attache a sample workbook. Click to Go Advanced, you will find a paper clip icon to upload a sample workbook by following the simple instructions.
    Regards
    sktneer


    Treat people the way you want to be treated. Talk to people the way you want to be talked to.
    Respect is earned NOT given.

  3. #3
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Change content of one cell based on content of another

    Hi,

    You don't say whether S14 should contain the E14 value if D14 ONLY equals 1800, or if D14 is a non zero value. I'll assume the latter, and also that all values are on the May 7 sheet.

    Maybe in S14

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  4. #4
    Registered User
    Join Date
    07-25-2010
    Location
    Toronto, Canada
    MS-Off Ver
    Excel 2003
    Posts
    11

    Re: Change content of one cell based on content of another

    Thank you
    I would like 1800 to equal to '2' so when I write 1800 in D14 the value of '2' appears in S14. So would the formula be =IF(D14<>2,S14,"")?

    I've attached two images. one is the Formual Tab and the other is the May 7 tab.

    I hope that clarifies what I'm trying to say.

    Formula Tab.pngMay 7 Tab.png

  5. #5
    Registered User
    Join Date
    07-25-2010
    Location
    Toronto, Canada
    MS-Off Ver
    Excel 2003
    Posts
    11

    Re: Change content of one cell based on content of another

    Mr. Buttrey, I believe I got the formula.

    I have placed =IF(D14<>0,Formula!B12,"") in the function and received a '2'. Does this sound correct to you? To add to this, how would I amend the formula so that it can read B13 as well as an alternate option?

  6. #6
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Change content of one cell based on content of another

    Hi Flora,

    Based on your example in the Formula tab I think you probably need a VLOOKUP() function

    i.e.

    Formula: copy to clipboard
    Please Login or Register  to view this content.

    but if not upload the workbooks

  7. #7
    Registered User
    Join Date
    07-25-2010
    Location
    Toronto, Canada
    MS-Off Ver
    Excel 2003
    Posts
    11

    Re: Change content of one cell based on content of another

    Hi Richard,

    Sorry I've been off for a few days and I'm still not concentrating very well, so I applogize if this post seems obscure.

    I have placed =VLOOKUP('May 7'!D14,'Formula'!A$12:A$13,2.False) but it's giving me an error. In the Formula sheet A12=2 & A13=12. I've tried placing both values in the formula but it's not taking. I know this is an easy fix but I can't seem to figure it out.

    I've uploaded the workbook for you. I have highlighted the two columns in the May 7th worksheet as well as the two rows in the Formula worksheet.



    I really want to Thank you for all your help.
    Attached Files Attached Files

  8. #8
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,649

    Re: Change content of one cell based on content of another

    I think the formula in S14 on May 7 sheet should be........

    Please Login or Register  to view this content.
    You are getting #value error because A12:A13 has different format than that of D4. D4 is formatted as Text and A12:A13 is formatted as General. Make the format of lookup value and lookup array same and your formula will work.

    I hope this helps.

  9. #9
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Change content of one cell based on content of another

    Hi Flora,

    Can you clarify exactly what you expect to see and add some typical entries and manually add the results you expect to see. I can see no reference to the Vlookup() formula you mention.

    Neither am I clear whether the entries you show on the Formula sheet are the only entries that will ever be there or not. I suspect not since I'm presuming this is some sort of database that will list many employees.

+ 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. Change content of one cell based on content of another
    By stlellen in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 04-18-2014, 03:26 PM
  2. Automatically copy cells content based on the content of another cell.
    By chrisbarlow1984 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-01-2014, 11:13 AM
  3. Change ws3 Cell Content Depending On ws1 Content
    By heliskier89 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-24-2011, 04:52 PM
  4. Change cell content based from another cell's content
    By RochesterColonial in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-24-2010, 03:43 PM
  5. Replies: 2
    Last Post: 12-19-2006, 10:50 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