有一个网站,我已经登录。我无法在登录表单的输入框中输入内容。
我试图获取标签名称为“ input”的关联对象,但无法检索它。
class Attachment(models.Model):
file = models.FileField(upload_to=log_att_path)
log_sender = models.ForeignKey(
LogSender,
related_name='attachments',
on_delete=models.CASCADE
)
timestamp = models.DateTimeField(auto_now_add=True)
attachment_url = models.TextField(default=False)
```
这是页面的检查元素
答案 0 :(得分:0)
VBA运行时错误“ 91”:对象变量或With块变量未设置Internet Explorer控件
尝试类似这样的操作,直到元素可用,然后再单击它。我之所以使用HTMLGeneric元素,是因为我不知道您要处理哪种类型的元素。
Dim element As HTMLGenericElement
Do
Set element = HTMLdoc.all("eomSearchMain:advOrderSearch")
DoEvents
Loop While element Is Nothing
element.Click
'IE busy And readyState wait here
'Document.readyState wait here
Do
Set element = HTMLdoc.getElementById("frmOrderListing:lOrderListing:0:optxtOrderNumberActionFocusLink")
DoEvents
Loop While element Is Nothing
element.Click
'IE busy And readyState wait here
'Document.readyState wait here
信用:link