Skip to content Skip to sidebar Skip to footer

How To Compare Values Of Cells In If Condition?

It works as follows: Identify the value just edited is 'Completed'or 'Cancelled'. If true, select the 'Timestamp' value in previous column. Lookup the 'Timestamp' in a different ta

Solution 1:

Try if(sheetCells[i][0]==TimeStamp) since The == operator will compare for equality after doing any necessary type conversions. The === operator will not do the conversion, so if two values are not the same type === will simply return false.But even == didn't work in your case. So,I believe you are getting time stamp and In javascript there should be specific method to compare time stamps or you have to calculate difference in time using math method and then if difference stands as 0 then the time stamp is same else there is some difference


Post a Comment for "How To Compare Values Of Cells In If Condition?"