+ Reply to Thread
Results 1 to 4 of 4

Delete links to external sources and retain formulas in cells.

  1. #1
    Registered User
    Join Date
    11-06-2014
    Location
    old greenwhich, NY
    MS-Off Ver
    2010
    Posts
    4

    Delete links to external sources and retain formulas in cells.

    Hello All,

    I have this code below altered from a previous post:

    Please Login or Register  to view this content.

    This code is trying to get rid of the external links within a cell while retaining the formula that is included within the same cell.Im getting a Compile error "Method or data member not found on the "NewName:=Thisworkbook.wbk" Here is an example of my problem:


    =IF(ISNA(MATCH(D3,'H:\Entry Support\Income Allocators\ESOMM\2014\2014 09\[ESOMM Operating Income 201409 version 100.xlsm]2013 BI by Partner'!$2:$2,0)),0,MATCH(D3,'H:\Entry Support\Income Allocators\ESOMM\2014\2014 09\[ESOMM Operating Income 201409 version 100.xlsm]2013 BI by Partner'!$2:$2,0))


    The strings highlighted in red are the links i want to remove and retain all the formula around it. These links were formed after copying data from an old sheet into a new sheet. There will be many more of the same actions like this monthly so just trying to find an easier solution.


    Thanks,

  2. #2
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,942

    Re: Delete links to external sources and retain formulas in cells.

    Change

    NewName:=ThisWorkbook.wbk

    to either

    NewName:=wbk.Name

    NewName:=ThisWorkbook.Name

    depending on which you mean.
    Bernie Deitrick
    Excel MVP 2000-2010

  3. #3
    Registered User
    Join Date
    11-06-2014
    Location
    old greenwhich, NY
    MS-Off Ver
    2010
    Posts
    4

    Re: Delete links to external sources and retain formulas in cells.

    I'm getting this error when I tried both:

    Application-defined or object-defined error.

    Could you explain what these two expressions you've stated before mean?


    Thanks,

  4. #4
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,942

    Re: Delete links to external sources and retain formulas in cells.

    The important thing that you have not stated is where you want the links to point to. There are three choices: The activeworkbook (the workbook with the Links), ThisWorkbook (the workbook with the code) or wbk, which is a workbook named Book2.xlsm (you used Set wbk = Workbooks("Book2.xlsm") ) - or a fourth, which is another workbook altogether.

    Whatever you do, you need to make sure that the sheet names in the workbook are the same as in the current linked workbook - try each of these three:

    Please Login or Register  to view this content.
    Last edited by Bernie Deitrick; 11-07-2014 at 03:31 PM.

+ 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. Replies: 1
    Last Post: 02-15-2013, 01:30 PM
  2. [SOLVED] Excel formulas not updating data from external sources.
    By musik7 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-15-2012, 10:32 AM
  3. Excel Crashes when updating links to external data sources
    By cooper1308 in forum Excel General
    Replies: 1
    Last Post: 08-26-2009, 01:44 AM
  4. Links to external sources and resource issue.
    By Rgaherty in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-15-2008, 08:33 PM
  5. Deleting links to external sources
    By vioravis in forum Excel General
    Replies: 1
    Last Post: 07-30-2007, 09:44 AM

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