Skip to content

Commit 666e90a

Browse files
Copy Bulk Sysids from a List of Selected Records (#2106)
* Create Copy Bulk SysIDs Copy Bulk Sysid UI Action as a List Choice * Delete Client-Side Components/UI Actions/Copy Bulk SysIDs Selected wrong folder * Create Copy Bulk Sysids Copy Bulk Sysids from List view * Create README.md Readme file for instructions and usage for Copying Bulk Sysids * Rename Copy Bulk Sysids to Copy Bulk Sysids.js Updated extension
1 parent 45f2aec commit 666e90a

File tree

2 files changed

+35
-0
lines changed

2 files changed

+35
-0
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
var sysIds = g_list.getChecked();
2+
copyToClipboard(sysIds);
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# Copy SysIDs in Bulk — ServiceNow Utility
2+
3+
> Simplify copying checked sys_ids from a list view with a one-click UI Action.
4+
5+
---
6+
7+
## Purpose / Use Case
8+
9+
Often, you may need to extract sys_ids from records listed in a ServiceNow list view (for scripting, validations, data workflows, etc.). Instead of exporting CSVs or manually gathering IDs, this utility enables direct copying of the selected records’ sys_ids (comma-separated) from the list itself.
10+
11+
---
12+
13+
## How It Works
14+
15+
It adds a global UI Action (on lists) that, when clicked, collects the sys_ids of checked records and copies them to the clipboard using a small client-side script.
16+
17+
---
18+
19+
## Installation Steps
20+
21+
1. Navigate to **System Definition > UI Actions**.
22+
2. Create a **new UI Action** with these settings:
23+
- **Name**: e.g. `Copy Bulk SysIDs`
24+
- **Table**: `Global` (so it works on every list)
25+
- **Check** the **Client** and **List** checkboxes (so it appears in list context on client side)
26+
3. In the **Onclick / Client script** field, paste:
27+
28+
```javascript
29+
var sysIds = g_list.getChecked();
30+
copyToClipboard(sysIds);
31+
32+
## Result
33+
<img width="1829" height="901" alt="image" src="https://github.com/user-attachments/assets/bdbd7c11-9a1a-42a3-972e-6920228fe065" />

0 commit comments

Comments
 (0)