跳到主要内容

如何在未打开/关闭的Excel工作簿文件中引用或链接值?

通常,在引用其他工作簿中的单元格值时,需要首先打开该工作簿。 如何直接从封闭的工作簿中引用单元格值? 本文将向您展示从未打开的工作簿文件的某个工作表中引用单元格值的方法。

带有公式的未打开/关闭的Excel文件的参考值
使用 Kutools for Excel 从未打开/关闭的 Excel 文件插入某个工作表的所有数据


带有公式的未打开/关闭的Excel文件的参考值

假设名为test的已关闭工作簿位于计算机的路径E:\ Excel file \中,并且您要引用此已关闭工作簿的Sheet2中单元格A2的值。 请执行以下操作。

1.选择一个空白单元格以放置引用的单元格值,在“公式栏”中输入公式,然后按 输入 键。 看截图:

=INDEX('E:\Excel file\[test.xlsx]Sheet2'!A:A,2,1)

:

1)。 在公式, E:\ Excel文件\ 是未打开的工作簿的完整文件路径, 测试.xlsx 是工作簿的名称,Sheet2是工作表名称,其中包含您需要引用的单元格值,A:A,2,1表示将在关闭的工作簿中引用单元格A2。 您可以根据需要进行更改。
2)。 如果要手动选择要参考的工作表,请应用以下公式。 应用公式后, 选择工作表 弹出对话框,请选择一个工作表,然后单击“确定”按钮。 然后,将立即引用此工作表的某些单元格值。

=INDEX('E:\Excel file\[test.xlsx]sheetname'!A:A,2,1)


使用 Kutools for Excel 从未打开/关闭的 Excel 文件插入某个工作表的所有数据

如果要从关闭的Excel文件中插入整个工作表内容,则在这里建议您 在光标处插入文件 实用程序 Kutools for Excel。 请按照以下步骤完成操作。

申请前 Kutools for Excel首先下载并安装.

1.选择您要引用的工作表开始的空白单元格,然后单击 Kutools 加 > 进出口 > 在光标处插入文件

2.在 在光标处插入文件 对话框中,单击 浏览 按钮。

3.在 选择要插入单元格光标位置的文件 对话框中,找到并选择要引用的已关闭工作簿,然后按 可选 按钮。 看截图:

4.现在返回到插入 光标处的文件 对话框中,您可以选中 仅值(无公式)不传输格式 选项,然后单击 OK 按钮。 在下一个弹出 选择一个工作表 对话框中,指定一个工作表,然后单击 OK 按钮。 看截图:

现在,当前工作表中引用了指定的未打开工作簿的选定工作表中的全部内容。

备注:除了引用未打开的工作簿中的值外,您还可以使用此实用工具来引用未打开的Txt或CSV文件中的值。

  如果您想免费试用(30天)此实用程序, 请点击下载,然后按照上述步骤进行操作。


相关文章:

最佳办公生产力工具

🤖 Kutools 人工智能助手:基于以下内容彻底改变数据分析: 智能执行   |  生成代码  |  创建自定义公式  |  分析数据并生成图表  |  调用 Kutools 函数...
热门特色: 查找、突出显示或识别重复项   |  删除空白行   |  合并列或单元格而不丢失数据   |   不使用公式进行四舍五入 ...
超级查询: 多条件VLookup    多值VLookup  |   跨多个工作表的 VLookup   |   模糊查询 ....
高级下拉列表: 快速创建下拉列表   |  依赖下拉列表   |  多选下拉列表 ....
列管理器: 添加特定数量的列  |  移动列  |  切换隐藏列的可见性状态  |  比较范围和列 ...
特色功能: 网格焦点   |  设计图   |   大方程式酒吧    工作簿和工作表管理器   |  资源库 (自动文本)   |  日期选择器   |  合并工作表   |  加密/解密单元格    按列表发送电子邮件   |  超级筛选   |   特殊过滤器 (过滤粗体/斜体/删除线...)...
前 15 个工具集12 文本 工具 (添加文本, 删除字符,...)   |   50+ 图表 类型 (甘特图,...)   |   40+ 实用 公式 (根据生日计算年龄,...)   |   19 插入 工具 (插入二维码, 从路径插入图片,...)   |   12 转化 工具 (小写金额转大写, 货币兑换,...)   |   7 合并与拆分 工具 (高级组合行, 分裂细胞,...)   |   ... 和更多

使用 Kutools for Excel 增强您的 Excel 技能,体验前所未有的效率。 Kutools for Excel 提供了 300 多种高级功能来提高生产力并节省时间。  单击此处获取您最需要的功能...

产品描述


Office Tab 为 Office 带来选项卡式界面,让您的工作更加轻松

  • 在Word,Excel,PowerPoint中启用选项卡式编辑和阅读,发布者,Access,Visio和Project。
  • 在同一窗口的新选项卡中而不是在新窗口中打开并创建多个文档。
  • 每天将您的工作效率提高50%,并减少数百次鼠标单击!
Comments (7)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
The Kutools solution to this is useless. It inserts the entire file and not a range or specific cells. What a waste. If Kutools wanted to make a useful tool, they could write something to overcome the Index(Indirect limitation, allowing for dynamic content sourcing without writing VBA
This comment was minimized by the moderator on the site
Hi CJ,
Thank you for your advice.
This comment was minimized by the moderator on the site
I have a worksheet for logging shipments. I want to retrieve the freight costs captured on shipping documents in different workbooks without VBA, whether the workbooks are opened or closed, and have the results returned to my shipping log per the respective shipment. I've manually typed the following path using the "Index" function and it works.

Ex #1: =IF(AND($G5>0,$I5>0,INDEX('V:\Operations\Shipping Log\Argentina\CY 2018\[AR18001_Order# 123456_Customer Name.xlsx]Shipping Document'!$AA:$AA,2,1),0)

The challenge I have is the country, calendar year, log number, order number and customer name are subject to change per shipment. To account for this I used the "Concatenate" function to build the path and replace the manually input information referenced above based on certain fields the user populates in the Shipping Log. First, I tested the "Concatenate" function to build the path and it worked for the consecutive rows. Next, I combined the "Concatenate" function with the "Index" function (to access the closed workbook) and received the text result of the path instead of the value of the desired cell. What am I missing?


Ex #2:=IF(AND($G5>0,$I5>0,INDEX(CONCATENATE("'V:\Operations\Shipping Log\",$C5,"\","CY 20",SUM($JK$2:$NG$2),"\","[",$D5,"_",$I5,"_",$G5,".xlsx]Shipping Document'!$AA:AA,2,1),0)"),"")

$C5 retrieves the country

$JK$2:$NG$2 retrieves the suffix of the calendar year

$D5 retrieves the shipping log number

$I5 retrieves the order number

$G5 retrieves the customer name

AA2 houses the desired value


I also tried "VLOOKUP" function instead of "Index" but received a "#VALUE!" error message.


Ex #3: =IF(AND($G5>0,$I5>0,VLOOKUP("Freight",(CONCATENATE("'V:\Operations\Shipping Log\",$C5,"\","CY 20",SUM($JK$2:$NG$2),"\","[",$D5,"_",$I5,"_",$G5,".xlsx]Shipping Document'!$AA:$AA"),2,FALSE),"")
This comment was minimized by the moderator on the site
Gray, I think I found a solution for you. Please contact me if you are still looking: dons(at )premierconstructionspreadsheets(dot )com
This comment was minimized by the moderator on the site
Same thing happened to me. Exactly the same. Did you find a solution?
This comment was minimized by the moderator on the site
Same thing happened to me. Exactly the same. Did you find a solution?
This comment was minimized by the moderator on the site
Dear Gray,
Do you mind uploading your related workbooks?
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations