title: Using a custom function in Data Validation
body: <p>I am trying to use a custom function developed in Google Script to validate a value in the spreadsheet.</p>
  
  <p><img src="https://i.stack.imgur.com/HKlks.jpg" alt="For a cell I add a custom function call"></p>
  
  <p>However I get a response: There is a problem "Enter a value that satisfies the formula: =validateContent()"</p>
  
  <p>The function itself has not been called at all.</p>
  
  <p>Am I pushing Google Spreadsheet validation too far here with custom function?<br>
  I was expecting my function to return true or false, is that how it is suppose to work?</p>
  
  <pre><code>function validateContent() {
  
    var val = SpreadsheetApp.getActiveSpreadsheet().getActiveCell().getValue();
  
    if (val == value) return true;
  
    return false;
  
  }
  </code></pre>