vba 在一个驱动器/SharePoint 中链接两个 Excel 工作表
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/27263188/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Linking Two Excel Worksheets in One Drive / SharePoint
提问by Syed Nizamudeen
I'm trying to Link multiple Excel files and Upload to One Drive. while opening the Consolidated Excel file from One Drive through browser, displays warning as
我正在尝试链接多个 Excel 文件并上传到一个驱动器。通过浏览器从 One Drive 打开 Consolidated Excel 文件时,显示警告为
Links DisabledLinks to external workbooks are not supported and have been disabled.
链接已禁用不支持并已禁用指向外部工作簿的链接。
What i need is(3 files created in One Drive)
我需要的是(在一个驱动器中创建的 3 个文件)
File 1: Excel File 1
文件 1:Excel 文件 1
File 2: Excel File 2
文件 2:Excel 文件 2
File 3: Consolidated Excel File(linked with Excel File 1 and Excel File 2)
文件 3:合并的 Excel 文件(与 Excel 文件 1 和 Excel 文件 2 链接)
links to be created from File 3to File 1& File 2inside One Drive. Changes from File 1 & File 2 to be immediately Updated to File 3.
要在 One Drive 中从文件 3创建到文件 1和文件 2 的链接。文件 1 和文件 2 的更改将立即更新到文件 3。
回答by Omar
The following solution does NOT work using a web browser.
以下解决方案不适用于 Web 浏览器。
Note: The CID link provided below is a made up ID. It is just a sample, for visual purposes. Each OneDrive email account has a different and unique CID.
注意:下面提供的 CID 链接是一个虚构的 ID。它只是一个示例,用于视觉目的。每个 OneDrive 电子邮件帐户都有一个不同且唯一的 CID。
Get your CID
获取您的客户 ID
If you already know your CID, go to step 4
如果您已经知道您的客户 ID,请转到步骤 4
- Go to onedrive.live.comand log in to your account (where the files are parked)
Open any folderand copy the link from the address bar. For visual purposes...Ej, https://onedrive.live.com/?cid=1A23456CD7EF8GHI&id=1A23456CD7EF8GHI!107
- Step 2.1:
- 转到onedrive.live.com并登录您的帐户(文件所在的位置)
打开任何文件夹并从地址栏中复制链接。出于视觉目的...Ej,https://onedrive.live.com/ ?cid=1A23456CD7EF8GHI &id =1A23456CD7EF8GHI!107
- 步骤 2.1:


- Step 2.2:
- 步骤 2.2:


- Extract your CID from that link (
https://onedrive.live.com/?cid=1A23456CD7EF8GHI&id=1A23456CD7EF8GHI!107). The CID It's a 16-digit alphanumeric ID. On this example, it would be this: 1a23456cd7ef8ghi
- 从该链接 (
https://onedrive.live.com/?cid=1A23456CD7EF8GHI&id=1A23456CD7EF8GHI!107) 中提取您的 CID 。CID 这是一个 16 位字母数字 ID。在这个例子中,它是这样的:1a23456cd7ef8ghi
Create a local network drive/place
创建本地网络驱动器/位置
- Now, we'll use your CID to create/edit a link to mapOneDrive as a network location or as a network driveonto your local computer.
- Network Location:
https://d.docs.live.net/1A23456CD7EF8GHI/ - Network Drive (FTP Drive):
\\d.docs.live.net@SSL\DavWWWRoot\1A23456CD7EF8GHI\ - Just in case you're wondering, the user nameand password(credentials) are the same as your OneDrive account. Use the completeemail address as user name
- Network Location:
- Done!
- 现在,我们将使用您的 CID 创建/编辑链接以将OneDrive 作为网络位置或网络驱动器映射到您的本地计算机上。
- 网络位置:
https://d.docs.live.net/1A23456CD7EF8GHI/ - 网络驱动器(FTP驱动器):
\\d.docs.live.net@SSL\DavWWWRoot\1A23456CD7EF8GHI\ - 以防万一,用户名和密码(凭据)与您的 OneDrive 帐户相同。使用完整的电子邮件地址作为用户名
- 网络位置:
- 完毕!
Please remember that your OneDrive CID would different, than the one I provided on this example, since each account has a unique CID. Please update the link on step 4 accordingly
请记住,您的 OneDrive CID 与我在此示例中提供的不同,因为每个帐户都有一个唯一的 CID。请相应地更新第 4 步中的链接
Making OneDrive cloud service work for us =)
让 OneDrive 云服务为我们服务 =)
Now that you set up the "environment" you will be able to work with your excel workbook located in OnceDrive, like if they are local files. With a network drive/place mapped on your computer, you can now open your OneDrive files straight from that network drive/place.
现在您设置了“环境”,您将能够使用位于 OnceDrive 中的 Excel 工作簿,就像它们是本地文件一样。将网络驱动器/位置映射到您的计算机上后,您现在可以直接从该网络驱动器/位置打开 OneDrive 文件。
You can also use the same link from step 4 into our Excel formulas. If the file names are File1.xlsx, File2.xlsxand File3.xlsx; this is how your formulas would look on File3.xlsx:
您还可以将步骤 4 中的相同链接用于我们的 Excel 公式。如果文件名是File1.xlsx,File2.xlsx和File3.xlsx; 这就是您的公式的外观File3.xlsx:
|-----A-----|-----B------------------------------------------------------------------------------|
1| Name | Address |
------------------------------------------------------------------------------------------------|
2| ='https://d.docs.live.net/1a23456cd7ef8ghi/SomeFolder/[File1.xlsx]Sheet1'!$A1 | 456 Somewhere St
------------------------------------------------------------------------------------------------|
3| John Doe | =='https://d.docs.live.net/1a23456cd7ef8ghi/SomeFolder/[File2.xlsx]Sheet1'!$A1
------------------------------------------------------------------------------------------------|

