Avatar

Level 7

For a button I have the script below to unlock the field: form1.PageA.Sub_A.Table1.Item.Equipment

The type read only field above it is into repeating subform. The script works if I do not add any instances.

If I add a instance unlocks only the first field and the other remain locked!

Any suggestion?

Thanks

var

flag = false;

while

(flag != true){

var CheckPW = xfa.host.response("Password required", "PassWord", "", 0);

if (CheckPW == "123"){

form1.PageA.Sub_A.Table1.Item.Equipment.access = "";

flag = true;

}

else {

if (CheckPW == ""){

flag = true;

} else {

xfa.host.messageBox("Wrong Password, please try again!", "",0,0);

}

}