javascript - Adobe Acrobat 取消选中复选框 javascript 功能不起作用
问题描述
我正在尝试根据复选框值选中或取消选中特定的复选框。当我选中该框时,其他框将被选中,但如果我取消选中该框,则其他框不会被取消选中。我尝试了鼠标退出和鼠标向上触发器,结果相同。
if (this.getField("Check Box2").value == "On")
{
this.getField("Check if this is an").value = "On";
this.getField("Check 1").value = "On";
this.getField("Check Box230").value = "Yes";
}
else //if (this.getField("Check Box2").value == "Off")
{
//this.getField("Check if this is an").value = "Off";
this.getField("Check if this is an").checkThisBox(0, false)
this.getField("Check 1").value = "Off";
this.getField("Check Box230").value = "Off";
}
我已经尝试了 2 个if
语句,以及 anif/else
以及 the.value = "Off"
和checkThisBox(0, false)
方法。当我使用控制台中的任何一种方法运行单行时,它都可以工作。
解决方案
我更改了字段名称,现在它可以工作了。
推荐阅读
- database-design - 您应该如何建模数据库以存储具有不同频率的分钟、小时、天和月的价格
- r - 我应该用整个数据集调整学习器吗?
- cypress - Cypress 双击或单击 + 输入操作不会按预期触发 DOM 更改
- typescript - 在 Typescript 中通过缩小将类型分配给对象值
- javascript - ICM广播案例列表搜索
- python - 通过添加索引值对 JSONField 进行排序?
- database - 是否有专门为字符串搜索设计的数据库?
- javascript - 当通过父项更改道具时,React.js 子组件不会更新
- discord.js - 如何将我的解禁代码实现为工作代码
- javascript - 显示多次的 Javascript 警报