+ Reply to Thread
Results 1 to 5 of 5

Loss of cell reference

  1. #1
    Registered User
    Join Date
    05-17-2007
    Posts
    2

    Loss of cell reference

    I inherited a workbook from another worker. On sheet 2 a certain cell references a cell in sheet 1 and displays the contents of that cell. If I change the reference the cell only displays the new reference and not the contents of the cell referenced.

    Example: On Sheet 1 cell C11 contains CAT and cell C12 contains DOG. On Sheet 2 a cell contains the reference =Sheet 1!C11 and shows CAT. If I change the reference to =Sheet 1!C12 the cell shows =Sheet 1!C12 rather than DOG. After it has been changed I cannot get the cell to accept another working reference. What setting or condition will caus this to happen?

  2. #2
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,525
    Hi there,

    The format of the cell is changing to text whenever you change the formula (probably because that's how the cell was formatted originally).

    Firstly, you'll need to change the format of the cell to Custom by:

    1. Ensure the cursor is on the cell in question
    2. From the Format menu select Cells
    3. Select the Number tab from the Format Cells dialog box
    4. Select Custom from the Category list
    5. Select the format of the cell from Type
    6. Click OK

    Then remove the single apostrophe ' at the start of the formula.

    HTH

    Robert

  3. #3
    Registered User
    Join Date
    05-17-2007
    Posts
    2
    Thanks Trebor76,
    I tried your solution but it doesn't really fix it. I thought it had, but it didn't stay reformated and I couldn't get it to work the second time.(?) Also, I'm sorry about the apostrophe on my example. The sheets in the workbook are named and to the best of my knowledge the apostrophe automatically goes with the "named" sheet, but I guess I just stuck it in out of habit of looking at the named sheets.
    If you have any more ideas I would appreciate it.
    Thanks again.

  4. #4
    Valued Forum Contributor mudraker's Avatar
    Join Date
    11-10-2003
    Location
    Melbourne, Australia
    Posts
    3,983
    It is possible that the cell on sheet2 formatting has been change to Text or the formula has a ' at the start. Any entry in a cell starting with ' is treated as text.
    Please Read Forum Rules Before Posting
    Wrap VBA code by selecting the code and clicking the # icon or Read This
    How To Cross Post politely

    Top Excel links for beginners to Experts

    If you are pleased with a member's answer then use the Scales icon to rate it
    If my reply has assisted or failed to assist you I welcome your Feedback.

  5. #5
    Valued Forum Contributor
    Join Date
    02-09-2006
    Location
    Melbourne, Australia
    MS-Off Ver
    Office 2016
    Posts
    1,075
    Quote Originally Posted by roloto
    Example: On Sheet 1 cell C11 contains CAT and cell C12 contains DOG. On Sheet 2 a cell contains the reference =Sheet 1!C11 and shows CAT. If I change the reference to =Sheet 1!C12 the cell shows =Sheet 1!C12 rather than DOG. After it has been changed I cannot get the cell to accept another working reference. What setting or condition will caus this to happen?
    Sometimes Excel gets its cell formats confused. On sheet 2 cell C11 click on Data, Text to Columns. Don't change any of the default settings, just click on Next, then Next. In the final window, make sure that the General option is selected, then click on Finish. If the formula still appears, press F2 then hit the ENTER key. Sometimes this process resets things.

    If this works, you can apply the process to entire columns, but only one column at a time.
    Trish in Oz
    -------------
    A problem well defined is a puzzle half solved


    If you attach a sample of your workbook it will be easier to find a solution. Remember to remove/replace sensitive data before uploading the file. Look here if you need help with attachments:
    http://www.excelforum.com/faq.php?fa...b3_attachments

+ 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