创建指向另一个工作表的超链接 [英] Create hyperlink to another sheet

查看:21
本文介绍了创建指向另一个工作表的超链接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的工作簿的第一页就像一个目录页.A 列中的每个单元格都包含一个 IP 地址字符串.对于每个 IP 地址字符串,都有一个以 IP 地址命名的工作表.

The first sheet of my workbook is like a contents page. Each cell in column A holds an IP address string. For each IP address string, there is a worksheet named with the IP address.

我想将 A 列单元格中的字符串转换为指向相应工作表(目标工作表的单元格 A1)的超链接.

I want to turn the string in the cells in column A into hyperlinks to their corresponding sheets (cell A1 of the destination sheet).

我只需要制作超链接的 VBA 行;我可以弄清楚循环等.记住要链接到的工作表的名称与将成为链接的单元格的值相同.

I only need the VBA line that makes the hyperlink; I can figure out the looping, etc. Remember that the name of the sheet to be linked to is the same as the value of the cell that will become the link.

研究只提出了提供一堆代码的论坛帖子,而没有解释任何代码.

Research has only brought up forum posts that give a stack of code without explaining any of it.

推荐答案

我录制了一个制作超链接的宏.结果就是这样.

I recorded a macro making a hiperlink. This resulted.

ActiveCell.FormulaR1C1 = "=HYPERLINK(""[Workbook.xlsx]Sheet1!A1"",""CLICK HERE"")"

这篇关于创建指向另一个工作表的超链接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆