FieldGroup Object Members in SuiteScript 2.1 Reference
The FieldGroup object in SuiteScript 2.1 manages UI field groups and their properties in NetSuite Suitelets.
The FieldGroup object is a critical component of the NetSuite SuiteScript 2.1 framework, specifically designed for managing field groups within Suitelets. This object allows developers to define how groups of fields behave in the user interface (UI), including features like collapsibility and visibility.
Key Properties of FieldGroup Object
| Property Name | Property Type | Description |
|---|---|---|
isBorderHidden | Boolean | Determines if a border appears around the field group. |
isCollapsible | Boolean | Indicates whether the field group can be collapsed. |
isCollapsed | Boolean | Defines if the field group is displayed collapsed by default. |
isSingleColumn | Boolean | Controls whether the field group is shown in a single column layout. |
label | string | The label that represents the field group in the UI. |
Practical Tips
- Naming Conventions: It's recommended to prefix custom UI elements with
custpageto avoid internal naming conflicts. - UI Consistency: Utilize the
FieldGroupto maintain a coherent layout for user inputs, improving usability and ease of navigation.
Example Usage
Here's an example of how to define and use a FieldGroup in a Suitelet:
1function onRequest(context) {2 var form = serverWidget.createForm({title: 'Sample Form'});3 var fieldGroup = form.addFieldGroup({id: 'custpage_sample_group', label: 'Sample Field Group'});4 5 // Set properties6 fieldGroup.isCollapsible = true;7 fieldGroup.isCollapsed = false;8 9 // Add fields to the group10 form.addField({id: 'custpage_field1', type: serverWidget.FieldType.TEXT, label: 'Field 1'});11 form.addField({id: 'custpage_field2', type: serverWidget.FieldType.TEXT, label: 'Field 2'});12 13 context.response.writePage(form);14}Conclusion
Using the FieldGroup object effectively enhances the usability of custom Suitelets. By defining clear grouping logic and leveraging its properties, developers can create intuitive interfaces that align with NetSuite's user experience standards.
Who This Affects
This content is particularly relevant for:
- Developers: who are designing user interfaces using Suitelets.
- Administrators: who may need to define custom forms and workflows.
Source: This article is based on Oracle's official NetSuite documentation.
Key Takeaways
- The
FieldGroupobject allows for customizable field grouping in Suitelets. - Key properties include
isBorderHidden,isCollapsible, andlabel. - Following naming conventions helps minimize conflicts within the UI.
Frequently Asked Questions (4)
Do I need to prefix custom FieldGroup IDs with 'custpage' in SuiteScript 2.1?
Can a field group be displayed collapsed by default in Suitelets?
Is it possible to hide the border around a FieldGroup in Suitelet?
How can I arrange fields in a single column layout within a FieldGroup in Suitelets?
Was this article helpful?
More in General
- Payment Date Prediction Feature in NetSuite
Payment Date Prediction in NetSuite utilizes machine learning to enhance financial planning by predicting invoice payment dates.
- NetSuite Ship Central Enhancements for Packing & Shipping
NetSuite Ship Central features enhance packing and shipping operations for improved efficiency and accuracy.
- Generative AI Features in NetSuite 2026.1
Discover new generative AI features in NetSuite 2026.1, enhancing reporting, search, predictions, and development productivity.
- Field Service Management Enhancements and Bug Fixes for 2026
Overview of the 2026 Field Service Management SuiteApp updates showcasing enhancements and bug fixes.
Advertising
Reach General Professionals
Put your product in front of NetSuite experts who work with General every day.
Sponsor This Category