Conditional Format Rule Members in SuiteScript
The ConditionalFormatRule object in SuiteScript defines properties for conditional formatting in spreadsheets, enhancing data visibility.
The ConditionalFormatRule object in SuiteScript offers a way to manage conditional formatting within a workbook. This enables developers to define specific formatting rules for spreadsheet data, ensuring better data representation and visibility.
What Are ConditionalFormatRule Object Members?
The ConditionalFormatRule object contains essential properties that define how data is formatted based on specific conditions. Here are its primary members:
| Member Name | Type | Description |
|---|---|---|
filter | workbook.TableColumnFilter | Determines which rows or cells to apply the conditional format to. |
style | workbook.Style | Specifies the style to be applied as the conditional format. |
Creating a Conditional Format Rule
Developers can utilize the workbook.createConditionalFormatRule(options) method to create an instance of this object. It is often used as a parameter in the workbook.createConditionalFormat(options) method.
Supported Script Types
This object is compatible with server scripts, allowing for broader application in SuiteScript functionalities.
Error Handling
When dealing with the ConditionalFormatRule members, you may encounter the following error code:
WRONG_PARAMETER_TYPE: This error is thrown if the value specified for thefilterproperty is not a validworkbook.TableColumnFilterobject.
Additional Resources
For further information, refer to the N/workbook Module documentation and familiarize yourself with the SuiteScript 2.x Script Types.
Key Takeaways
- The ConditionalFormatRule object is crucial for implementing dynamic formatting in workbooks.
- It includes properties like
filterandstylethat define formatting conditions. - The object is intended for use in server scripts, enhancing automation and data presentations.
- Understanding error codes like
WRONG_PARAMETER_TYPEhelps in troubleshooting.
Source: This article is based on Oracle's official NetSuite documentation.
Frequently Asked Questions (4)
Can ConditionalFormatRule be used in both client and server scripts in SuiteScript?
How do I create a ConditionalFormatRule in SuiteScript?
What types of errors should I watch for when using ConditionalFormatRule?
What are the primary properties of a ConditionalFormatRule in SuiteScript?
Was this article helpful?
More in Platform
- Style Object Members for Workbook API in NetSuite
The Style object provides customizable properties for workbook formatting in NetSuite, enhancing report and visualization functionality.
- Asynchronous HTTP Requests with SuiteScript Promises
Use SuiteScript to send asynchronous HTTP requests with promises for efficient error handling and response processing.
- Setting Sublist Field Values in SuiteScript
Set values for sublist fields in SuiteScript using the setSublistValue method. Understand required parameters and error handling.
- In This Help Topic
Explore N/log module guidelines, log levels, and script execution logs for efficient logging in SuiteScript.
Advertising
Reach Platform Professionals
Put your product in front of NetSuite experts who work with Platform every day.
Sponsor This Category