This topic is locked
[SOLVED]

 MakeReadOnly

3/6/2021 3:02:46 PM
PHPRunner General questions
R
RBrogen author

Hi Everyone,
I'm running into an issue where I get the error below for the code shown which is located in the JavaScript OnLoad event of the Edit page. I am trying to make the sessionNotes field readonly when it is being viewed by the client. I've checked and rechecked the code and it seems correct but I can't seem to get it to work. Any thoughts would be greatly appreciated.
ERROR:

Uncaught TypeError: sessionNotes.makeReadOnly is not a function



var sessionNotes = Runner.getControl(pageid,'session_Notes');
//UserGroup -3 is Client Group which only have access to their signature field

if (proxy["userGroup"] == -3)

{

sessionNotes.makeReadOnly();
}
R
RBrogen author 3/6/2021

NM folks ... duh I used .makeReadOnly instead of .makeReadonly ... damn syntax