Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/excel/23.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Html VBA Excel IE自动化:按自定义标记定位元素_Html_Excel_Vba - Fatal编程技术网

Html VBA Excel IE自动化:按自定义标记定位元素

Html VBA Excel IE自动化:按自定义标记定位元素,html,excel,vba,Html,Excel,Vba,我需要通过一个自定义html标记来选择一个元素,即,在下面的div元素中,自定义标记将是“somecustomtag” <div class="panel-one" somecustomtag="blue"> 我以前用过十几次,但在任何地方都找不到。.subTag的正确语法是什么?在您的例子中,somecustomtag是一个属性。您将通过以下代码片段获得somecustomtag的值 ob.getAttribute("somecu

我需要通过一个自定义html标记来选择一个元素,即,在下面的div元素中,自定义标记将是“somecustomtag

<div class="panel-one" somecustomtag="blue">

我以前用过十几次,但在任何地方都找不到。.subTag的正确语法是什么?

在您的例子中,somecustomtag是一个属性。您将通过以下代码片段获得somecustomtag的值

ob.getAttribute("somecustomtag")
ob.getAttribute("somecustomtag")