Google张:如何给importxml函数的个别结果添加链接?
Google sheets: how to add links to individual results of importxml function?
我正在使用以下等式搜索 Twitter 用户名:
=transpose(importxml(F1, "//span/a"))
其中F1为:https://twitter.com/search?f=users&vertical=default&q=from%3APERSON_NAME&src=typd
这 returns 很多结果(取决于有多少句柄),但我希望每个结果都是 link 推特,这样我就可以轻松验证句柄是否是我要找的人。
我试过这个的变体:
=transpose(concatenate("http://twitter.com/",importxml(F2, "//span/a")))
但结果是这样的:http://twitter.com/@handle1@handle2@handle3
所以这没有用。我需要http://twitter.com/@handle1, http://twitter.com/@handle2,等等
有没有办法在每个返回结果中添加一个link?
谢谢
您可以使用“&”连接字符串("A"&"B" = "AB")而不是连接,并使用数组公式以递归方式连接每个项目importXml 输出
=transpose(arrayformula("http://twitter.com/" & importxml(F2, "//span/a")))
希望对您有所帮助
我正在使用以下等式搜索 Twitter 用户名:
=transpose(importxml(F1, "//span/a"))
其中F1为:https://twitter.com/search?f=users&vertical=default&q=from%3APERSON_NAME&src=typd
这 returns 很多结果(取决于有多少句柄),但我希望每个结果都是 link 推特,这样我就可以轻松验证句柄是否是我要找的人。
我试过这个的变体:
=transpose(concatenate("http://twitter.com/",importxml(F2, "//span/a")))
但结果是这样的:http://twitter.com/@handle1@handle2@handle3
所以这没有用。我需要http://twitter.com/@handle1, http://twitter.com/@handle2,等等
有没有办法在每个返回结果中添加一个link?
谢谢
您可以使用“&”连接字符串("A"&"B" = "AB")而不是连接,并使用数组公式以递归方式连接每个项目importXml 输出
=transpose(arrayformula("http://twitter.com/" & importxml(F2, "//span/a")))
希望对您有所帮助