I am currently working on a Google Apps script that interacts with a Google spreadsheet. I'm facing an issue where I need to compare two cells, but they are showing as equal.
As part of my code logic, I have a for loop where the comparison is made:
if (cell[n][0] == failureCell)
{
failureFlag = 1;
Logger.log(cell[n][0]);
Logger.log(failureCell);
}
I have attempted converting both objects to strings using the toString() method, but this hasn't altered the results returned or logged by the system.
The log output is as follows:
[15-01-02 18:02:40:312 PST] Value1
[15-01-02 18:02:40:313 PST] FailValue
[15-01-02 18:02:40:524 PST] Value2
[15-01-02 18:02:40:525 PST] FailValue
[15-01-02 18:02:41:235 PST] Value3
[15-01-02 18:02:41:244 PST] FailValue
Below is a screenshot highlighting the relevant section in my spreadsheet: