Excel Connections - Edit Links Not Working? - excel

I do not know if this has been asked elsewhere but I looked and googled around for 30 mins and couldn't seem to find much. I have an old file with some drop down boxes for certain cells in an excel spreadsheet. I never really know how it works to be honest, and there are no macros within this sheet. But somehow, there are some links between some cells within the same file.
I recently changed file names and made copies to this master file, but some of the newer copies drop down boxes no longer work, and seems to be wanting to get to the original file. I tried editing this/these link(s) under the ribbon interface using 2016 - Data > Edit Links (under connections), and it brings up a pretty dialogue box, which has this change source button. But after I clicked it and selected the correct file (it's a circular reference, so it is the current file), it simply did nothing and did not update the file name or anything else shown within the dialogue box. And of course, my links are not fixed and the drop down boxes are not working.
I have uploaded the file here with all data stripped out, but the links are still intact there for your review. Any suggestions why I am seeing this? If I want to fix the links, what can I do to achieve that without fixing each of the cells individually? Thanks!
The file is here:
https://drive.google.com/open?id=1Sn27jnQmYvqWHho6Oa0yz7PXVGU4zwPJ

These reason you're seeing these links is that there are cells with Data Validation that point to an external file (cell B71, for example).
Remove all Data Validation that is referencing external files, save the file, and re-open. The links should be gone.

Related

Excel VBA: Export workbook without links to external data/convert formulas to its values

I have come to a problem that I had kind of sorted, but it came back to haunt me.
I have a set of Excel files with information (origin) that feed an aggregator/wrangler/chewer in Excel (workbook) and then I have a set of files, one for each subsidiary (output), that have the same structure (sheets, hyperlinks, headers) but only get the relevant info for that subsidiary.
Right now I have everything automated, I download, prepare the information and update the origin files, then the only thing I need to do is open and save all the other documents (aggregator/subsidiary exports) and I do it with VBA.
In order to distribute the subsidiary files I have to come up with something that can have the same structure as an Excel workbook, but doesn't have the links to the aggregator, or the subsidiaries won't be able to see the information as there will be #REF errors everywhere (even on some sheets headers).
The solution that I put in place was exporting the files as MHTML (Single File Web Page), as it managed to keep the sheets and hyperlinks and everything as intended, while only needing to "open [subsidiary file].xlsx & save as [subsidiary file].mht", but then I came to learn that it is only possible to open this file type in IE, which not everyone has access to.
Then my problem is that I need an alternative to this solution while using only "plain" solutions as the IT department won't allow me to use anything more than standard administrative tools (standard MS Office suite).
I tried to replicate the subsidiary files by copying and pasting every sheet, but then I cannot come up with a way to keep every formatting (mainly header width) as intended when pasting as "values", or as "values and source formatting", and this approach doesn't escalate well.
Do you know of a way of saving the file as is but without the formulas, or preventing them from updating when the file reopens (even if you say no to "update links" prompt sometimes some cells ate updated, don't know why), or some different approach?
The idea is to generate a file that no matter who the user is, and does, is able to see the information, and cannot screw the file/info in it, and if possible keeping it "easy" to update with a "simple" macro.
Kind regards,
Flávio

Excel "Forgets" revised linked values

My question is about issues with linked formulae in Excel spreadsheets.
I have a complicated structure of linked Excel Spreadsheets updated each month for Financial reporting.
The problem I have is that I will often update the values in source files. The links feed through correctly. Then I save all the files with the updated values in source and target files.
The problem arises when I reopen the files at a later time Excel forgets the revised figures. Then I need to go back and open the source files to make it pick up the new values again.
This problem is getting worse and worse, happening more and more for no apparent reason.I seem to spend half my time re-opening source files to update the linked values.
It seems like the Internal Table that Excel keeps for links is remembering old values and not saving the new one ones when I update the table.
So my question is this - how do I stop Excel doing this, how do I force it to remember the new linked values when they change in the source sheet and stop it from reverting to previous remembered values ?
To be clear, every time I do this I save everything in sight, but it makes no difference.
I have also tried to relinking to a different copy of a file and then linking back. This works sometimes, but not always.
If you're not getting this warning every time you open the 'target' workbook:
...then there's a good chance the problem is that, at some point, automatic update of external links was disabled.
To re-enable it:
On the Data tab, in the Connections group, click Edit Links
Click the Startup Prompt button
Choose the 1st or 3rd option.
Close & save all open workbooks and try it again.
If you chose the third option in step 3, all links should update automatically.
If you chose the first option in step 3, you will be asked if you want to update the links.
More Information:
Office.com : Control when external references (links) are updated

Excel will not update links, entire day of research and tests with random results

Short version, my Excel is set properly to automatically update links and all my files(locally stored) work fine for years. Suddenly one will not update linked data. I click on Connections>Edit connections>Check Status every linked file has "Warning! Values referring to other workbooks were not updated"
Refresh/calculate all does nothing.Changing to manual and doing this, back to auto, open and closing, restarting, using these same files on another PC. Nothing I did fixes it.
Clicking into an individual cell(F2) then back out though updates that one cell.
Open
All security settings are correct I am 98% sure, regardless whatever settings I had haven't changed and it did work.
I read a post that seemed exactly the same but his solution was enable protected content. Not the case here, i disabled it fully. There seems to be an error causing this possibly..
Long version. This is my largest file I continue to build
I have a main excel sheet that is linked to 35 workbooks. The source workbooks have lists of 3-4 columns, ranging from 1,000-10,000 rows long. The main WB uses index match for each source to pull two small fields. It takes about 5-6mins to do a calculate all with a desktop i7 3.64ghz ivy with 16gb ram.I never have issues on. Win 10/64bit and office 2016 64bit.
Some source files are .xls, I am in the process of changing them to xlsx but when I open the xls file and the values update. I then save as xlsx with a shorter name as well (trying to lighten the formulas) I go back to Connections>Edit connections>Check Status and the same warning is there. However I can click update values and it says OK.
This is very important file and is not physically monitored. Until something sells wrong I realize it wasnt updated, I am hoping for a concrete answer I can solve instead of just changing random things and hoping.. all help is greatly appreciated!
I actually resolved this by opening all source workbooks with the main workbook open and resaving them one by one (Status on some turned OK, most remained). Then I simply used Edit Links and Update Values for each connection which changed the status to OK. Saved the main workbook and no more issues..
Yes I need to take those suggestions and the workbook to the next level as it has clearly outgrown my skillset, but getting there..

Find Missing External Links in Excel

My spreadsheet has external links that I cannot find. It pops up the "workbook contains links to other data sources" warning upon opening. I don't want to just suppress the link warning, I need to remove the links.
I've tried all the basic ways to find external links that I'm aware of, and it's still happening. I've tried:
Searching for "[" in formulas in the entire workbook
Charts
Checking the named ranges from the Formulas/Name Manager menu
Checking objects
Conditional formatting menus
Is there another way to find external links? Thanks.
It can come from several sources. In my case, it came from the formula of a rule in the conditionnnal formatting. And no Excel search tool could find it.
In the case of an xlsx file, you can find it with an automatical approach:
In the Data tab, click on Edit links. All your links should be displayed. Mark down the values of the Location fields.
Unzip the xlsx file. Technically, an xlsx file is a zip container. See this post for more information.
Now search the whole directory for the Location strings.
Figure out to what your links are related. In my case, it was inside a x14:conditionalFormatting xml node. No wonder the Search tool did not work, it was not in a cell.
Modify that formula
Game over.
I would check the names collection in your workbook.
If you have a named range, for example, that has links to another workbook this will do this also... You can examine these in Excels Name Manager, or some VBA code executed in the debug window...like:
for i = 1 to names.Count: debug.Print Names(i): Next
I had an Excel 2013 file that whenever opened displayed a message regarding a missing external link. I could not find such a link (and location in file) using many suggestions and tools (Kutools, FormulaDEsk etc.).
Finally, I changed the file from xlsx to zip, opned and searched and deleted the gokder relating ton External Links (and changed back). Problem solved!

Excel Error: Removed Records: Sorting from /xl/worksheets/sheet10.xml part

I'm almost sure I will have to create a new excel file, but maybe at least here I get some ideas what was the source of the problem.
My excel file is constantly giving the following error:
Excel found unreadable content in 'filename.xlsm'. Do you want to recover the contents of this workbook? If you trust the source of this workbook, click Yes.
So I do. And the file opens as repaired showing:
Removed Records: Sorting from /xl/worksheets/sheet10.xml part.
The detail is that I don't even have a sheet10
Its a big excel file full of custom-objects. But I have no DB connections or autofilter so could not relate to AutoFilter Criteria Using Array (Error) - Too Large String? or xlsx error: "Removed Records: Named range from /xl/workbook.xml part" when tried to resolve errors.
Anyone has a clue what's going on?
tks in advance
try clearing the sort before saving down the workbook. When this happened to me I had my sheet references mixed up so the sort wasn't cleared
Sheets(yoursheetname).Sort.SortFields.Clear
I am afraid I cannot explain what is going on, but I had similar experience several times - always with XLSM file. In the latest case I learnt that Excel did not like the same range name used twice, when defined as Worksheet range name (we assumed it is safe to use it that way).
Our troubleshooting path is:
try to save file as XLSB (binary macro file) and either use XLSB file or save it back to XLSM
check file history (we always keep daily snapshots) and find when the problem firstly occurred; use previous version and port your changes
extract the code (via SVN code), create a new workbook and import the code back
Usually Step 1 solves the problem, but Step 3 never failed us.
Awesome,
This issue has been driving me crazy!
It seems that saving as the xlsb (binary) file PLUS adding the clearing of sort fields appears to have sorted out my issue.
I added the following code to the BeforeClose sub, it appears to clear the fields really quick, changes to my Dashboard and prompts for saving.
The xlsb file saved over a mb in file size and appears to load a little quicker!
Thanks for the pointers & support!
Private Sub Workbook_BeforeClose(Cancel As Boolean)
Dim Sht As Worksheet
' Clear all Sort Fields prior to Save & Exit
For Each Sht In Application.Worksheets
Sht.Sort.SortFields.Clear
Next Sht
aa1_Dashboard1.Select
aa1_Dashboard1.Activate
End Sub
I would like to add my own confirmation regarding clearing sort fields in your spreadsheet, as first suggested by Chris. I specifically had the error occur after I used column sorting in a VBA macro, so I deduced that the problem must be column/field-Sort related. It was.
Adding the line:
Sheets(yoursheetname).Sort.SortFields.Clear
after the sort command allowed the sorted columns to remain sorted (in my case), but cleared whatever was causing the
"Sorting from /xl/worksheets/sheet10.xml part." error when the file was next opened.
Many thanks for your support.
I don't know if this will help anyone but it's solved my problem. I had an excel sheet, nothing complex, just contacts, a much used file in Excel 2010 on Win7. Today I was using the 'filter' to select specific groups to email targeted content to. In the middle of selecting and copying to paste into Outlook, the document came up with a pop up as if I was installing something, then the 'installer' both of which I cancelled out of. The Document closed and then on trying to reopen, I was getting the error message. If I chose 'yes' to repair I was given just the subset of my filtered list, so about 40 of my 350 records, the rest lost. I googled and tried different things, including opening in Googledocs google sheets and nothing worked. I never 'saved' the repaired version as my old data wasn't in that. Just now, I right clicked on my document in explorer and chose "restore previous versions" and it brought me to the version of yesterday - thankfully, nothing added to it since then. Opened that one and bingo, it opened fine with ALL the data in it. I know the filter had corrupted it, so will be cautious next time I use it. I don't know why it doesn't like the filter but 4 hours on, i can now calm down and relax! Hope this helps someone.
was having this issue as well. I have a spreadsheet with multiple tabs (maybe 30 tabs?) and had filters on each sheet, and shared on SharedPoint. The error was not enabling editing of the file on SharePoint. I removed the filters on every sheet and uploaded back to SharePoint and the issue is gone!
I did what Chris mentioned above. Clear the sort fields in your spreadsheet.
Sheets(yoursheetname).Sort.SortFields.Clear
Also, save the file as *.xlsb.
That should get it to work.
When you get a message telling that Excel found unreadable.... just click "Open" and then close all the following messages you get.
-In the VBE open the project showing the name of Addin or the .xlsm.. the click anywhere in any module of the workbook as you are going to edit the text of the macro, then click save, select workbook type like Addin select the folder where you want to save it, give it a new name then click "Save", that is all you have to do, the new file you created will ok.

Resources