Error msg when trying to save code
I am trying to enter the following code into the On Success event of a form:
- //Populate Sources_Usernames field (used for dynamic views for external users)
for each person in input.Source_Player
{
if (count(frmPlayer[Name == person]) == 1)
{
recP = frmPlayer [Name == person];
if ((recP.Username != "") && (recP.Username != null))
{
if ((sourcesUsernamesStr != "") && (sourcesUsernamesStr != null))
{
sourcesUsernamesStr = sourcesUsernamesStr + "|" + recP.Username;
}
else
{
sourcesUsernamesStr = recP.Username;
}
}
}
}
for each person in input.Source_Scout
{
if (count(frmScout[Name == person]) == 1)
{
recS = frmScout [Name == person];
if ((recS.Username != "") && (recS.Username != null))
{
if ((sourcesUsernamesStr != "") && (sourcesUsernamesStr != null))
{
sourcesUsernamesStr = sourcesUsernamesStr + "|" + recS.Username;
}
else
{
sourcesUsernamesStr = recS.Username;
}
}
}
}
if (input.Sources_Usernames != sourcesUsernamesStr)
{
input.Sources_Usernames = sourcesUsernamesStr;
}
When I try to save the script I get the error message (without specification of a line):
Unknown column ELEMENT_TYPE in the table String_Expressions
I have entered the same code in another form and it worked.
Any ideas what might be wrong?