UI Builder : List Action | Export only Selected Items From List

  Рет қаралды 693

ServiceNow Guy

ServiceNow Guy

Күн бұрын

Hello Everyone,
We have created one use case video on List Action to export the selected records only in PDF formate. Basically the List action is created for the UI builder workspaces to perform any action on the list.
Now ‪@servicenow‬ has OOB Export button but that exports all the records present on the list view but we want the selective records only, So in order to fullfill this requirement we are creating the dynamic URL and hitting that from List Actions.
// Code from List Action :
function onClick() {
try{
var checkedRecords= g_list.getChecked();
var query="sys_idIN"+checkedRecords.toString();
var table= g_list.tableName;
var view= g_list.getView();
var url=table+"_list.do?PDF&sysparm_query="+query+"&sysparm_view="+view+"&sysparm_view=print&landscape=true";
top.location.href=url;
}catch(ex){
var message=ex.message;
alert("Errors:"+message);
}
}
Tags :
#servicenow #servicenowimplementation #Uibuilder #servicenowtraining

Пікірлер: 2
@151TUMAMA
@151TUMAMA 7 ай бұрын
Great Video. This is exacly what I need it!
@AnkitSinghRajput-ye6de
@AnkitSinghRajput-ye6de 4 ай бұрын
Great video. Thanks for helping the ServiceNow Community especially for Workspace and UI Builder things. My use case is : I want to export in both scenarios. If I have selected a few records that should get downloaded also we want to export all when I haven't selected any records. How can we achieve this?
Advance Reporting Conditions using Script in #servicenow
12:05
ServiceNow Guy
Рет қаралды 1,6 М.
ServiceNow Localization & Language Translation Explained
14:14
ServiceNow Guy
Рет қаралды 1,7 М.
Synyptas 4 | Жігіттер сынып қалды| 3 Bolim
19:27
Good teacher wows kids with practical examples #shorts
00:32
I migliori trucchetti di Fabiosa
Рет қаралды 11 МЛН
小丑家的感情危机!#小丑#天使#家庭
00:15
家庭搞笑日记
Рет қаралды 20 МЛН
Add a Button to the List Component using Declarative Actions
15:31
ServiceNow Dev Program
Рет қаралды 12 М.
The fastest way to iterate a List in C# is NOT what you think
13:42
Nick Chapsas
Рет қаралды 157 М.
DHH - Ruby on Rails, 37signals, and the future of web development
1:09:57
Football AI Tutorial: From Basics to Advanced Stats with Python
1:30:19
The Fastest Way to Modify a List in C# | Coding Demo
10:30
Zoran Horvat
Рет қаралды 24 М.
NSURLProtocol: How I Stole an App For My Wedding
56:25
Bryce Bostwick
Рет қаралды 45 М.
Agile Software Practice  -  Lecture 4
54:02
Diarmuid O Connor
Рет қаралды 38
Synyptas 4 | Жігіттер сынып қалды| 3 Bolim
19:27