Trait

com.google.appsscript.spreadsheet

DataValidationBuilder

Related Doc: package spreadsheet

Permalink

trait DataValidationBuilder extends Object

DataValidationBuilder Builder for data-validation rules. // Set the data validation for cell A1 to require a value from B1:B10. var cell = SpreadsheetApp.getActive().getRange('A1'); var range = SpreadsheetApp.getActive().getRange('B1:B10'); var rule = SpreadsheetApp.newDataValidation().requireValueInRange(range).build(); cell.setDataValidation(rule);

Annotations
@RawJSType()
Linear Supertypes
Object, Any, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. DataValidationBuilder
  2. Object
  3. Any
  4. AnyRef
  5. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def build(): DataValidation

    Permalink

    Constructs a data-validation rule from the settings applied to the builder.

  6. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  7. def copy(): DataValidationBuilder

    Permalink

    Creates a builder for a data-validation rule based on this rule's settings.

  8. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  9. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  10. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  11. def getAllowInvalid(): Boolean

    Permalink

    Returns true if the rule shows a warning when input fails data validation, or false if it rejects the input entirely.

    Returns true if the rule shows a warning when input fails data validation, or false if it rejects the input entirely. The default for new data-validation rules is true.

  12. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  13. def getCriteriaType(): DataValidationCriteria

    Permalink

    Gets the rule's criteria type as defined in the DataValidationCriteria enum.

    Gets the rule's criteria type as defined in the DataValidationCriteria enum. To get the arguments for the criteria, use getCriteriaValues(). To use these values to create or modify a data-validation rule, see withCriteria(criteria, args).

  14. def getCriteriaValues(): Array[AnyRef]

    Permalink

    Gets an array of arguments for the rule's criteria.

    Gets an array of arguments for the rule's criteria. To get the criteria type, use getCriteriaType(). To use these values to create or modify a data-validation rule, see withCriteria(criteria, args).

  15. def getHelpText(): String

    Permalink

    Gets the rule's help text, or null if no help text is set.

  16. def hasOwnProperty(v: String): Boolean

    Permalink
    Definition Classes
    Object
  17. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  18. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  19. def isPrototypeOf(v: Object): Boolean

    Permalink
    Definition Classes
    Object
  20. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  21. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  22. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  23. def propertyIsEnumerable(v: String): Boolean

    Permalink
    Definition Classes
    Object
  24. def requireDate(): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a date.

  25. def requireDateAfter(date: Date): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a date after the given value.

    Sets the data-validation rule to require a date after the given value. The time fields of the Date object are ignored; only the day, month, and year fields are used.

  26. def requireDateBefore(date: Date): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a date before the given value.

    Sets the data-validation rule to require a date before the given value. The time fields of the Date object are ignored; only the day, month, and year fields are used.

  27. def requireDateBetween(start: Date, end: Date): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a date between the given values, inclusive of the values themselves.

    Sets the data-validation rule to require a date between the given values, inclusive of the values themselves. The time fields of the Date objects are ignored; only the day, month, and year fields are used.

  28. def requireDateEqualTo(date: Date): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a date equal to the given value.

    Sets the data-validation rule to require a date equal to the given value. The time fields of the Date object are ignored; only the day, month, and year fields are used.

  29. def requireDateNotBetween(start: Date, end: Date): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a date not between the given values, inclusive of the values themselves.

    Sets the data-validation rule to require a date not between the given values, inclusive of the values themselves. The time fields of the Date objects are ignored; only the day, month, and year fields are used.

  30. def requireDateOnOrAfter(date: Date): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a date on or after the given value.

    Sets the data-validation rule to require a date on or after the given value. The time fields of the Date object are ignored; only the day, month, and year fields are used.

  31. def requireDateOnOrBefore(date: Date): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a date on or before the given value.

    Sets the data-validation rule to require a date on or before the given value. The time fields of the Date object are ignored; only the day, month, and year fields are used.

  32. def requireFormulaSatisfied(formula: String): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require that the given formula evaluates to true.

    Sets the data-validation rule to require that the given formula evaluates to true. This method is only available in the new version of Google Sheets.

  33. def requireNumberBetween(start: Number, end: Number): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a number between the given values, inclusive of the values themselves.

  34. def requireNumberEqualTo(number: Number): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a number equal to the given value.

  35. def requireNumberGreaterThan(number: Number): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a number greater than the given value.

  36. def requireNumberGreaterThanOrEqualTo(number: Number): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a number greater than or equal to the given value.

  37. def requireNumberLessThan(number: Number): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a number less than the given value.

  38. def requireNumberLessThanOrEqualTo(number: Number): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a number less than or equal to the given value.

  39. def requireNumberNotBetween(start: Number, end: Number): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a number not between the given values, inclusive of the values themselves.

  40. def requireNumberNotEqualTo(number: Number): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require a number not equal to the given value.

  41. def requireTextContains(text: String): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require that the input contains the given value.

  42. def requireTextDoesNotContain(text: String): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require that the input does not contain the given value.

  43. def requireTextEqualTo(text: String): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require that the input is equal to the given value.

  44. def requireTextIsEmail(): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require that the input is in the form of an email address.

  45. def requireTextIsUrl(): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require that the input is in the form of a URL.

  46. def requireValueInList(values: Array[String], showDropdown: Boolean): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require that the input is equal to one of the given values, with an option to hide the dropdown menu.

  47. def requireValueInList(values: Array[String]): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require that the input is equal to one of the given values.

  48. def requireValueInRange(range: Range, showDropdown: Boolean): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require that the input is equal to a value in the given range, with an option to hide the dropdown menu.

  49. def requireValueInRange(range: Range): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require that the input is equal to a value in the given range.

  50. def setAllowInvalid(allowInvalidData: Boolean): DataValidationBuilder

    Permalink

    Sets whether to show a warning when input fails data validation or whether to reject the input entirely.

    Sets whether to show a warning when input fails data validation or whether to reject the input entirely. The default for new data-validation rules is true.

  51. def setHelpText(helpText: String): DataValidationBuilder

    Permalink

    Sets the help text shown when the user hovers over the cell on which data-validation is set.

  52. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  53. def toLocaleString(): String

    Permalink
    Definition Classes
    Object
  54. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  55. def valueOf(): Any

    Permalink
    Definition Classes
    Object
  56. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  57. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  58. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  59. def withCriteria(criteria: DataValidationCriteria, args: Array[AnyRef]): DataValidationBuilder

    Permalink

    Sets the data-validation rule to require criteria defined in the DataValidationCriteria enum.

    Sets the data-validation rule to require criteria defined in the DataValidationCriteria enum. This is an advanced method used primarily to create a new data-validation rule based on the criteria and arguments of an existing rule; in most other cases, the require...() methods are easier to use.

Inherited from Object

Inherited from Any

Inherited from AnyRef

Inherited from Any

Ungrouped