Announcements
No record found.
DialogField dialogMyParameter; str myParameter = "Default value"; #define.CurrentVersion(1) #localmacro.CurrentList myParameter #endmacro public container pack() { // This method is used by batch platform to serialize batch parameters in a container return [#CurrentVersion, #CurrentList]; } public boolean unpack(container _packedClass) { // This method is used by batch platform to deserialize batch parameters from stored // batch parameter container Integer version = RunBase::getVersion(_packedClass); container packedData; switch (version) { case #CurrentVersion: [version, #CurrentList] = _packedClass; break; default: return false; } return true; } public Object dialog() { // This method is invoked when user opens batch parameter dialog // It helps to add parameters to batch class and set their default value DialogRunbase dialog = super(); dialogMyParameter = dialog.addField(enum2Str(Types::Integer), "My Parameter"); // Set a default value of parameter dialogMyParameter.value(myParameter); return dialog; } public boolean getFromDialog() { // This method is invoked by batch platform to read the values of parameters from batch // parameter dialog method myParameter = dialogMyParameter.value(); return super(); } public void run() { // This method is the entry point for the batch class info("Batch job started!"); // Access the parameter value entered by the user info("My Parameter: " + this.myParameter); // Your main batch logic goes here info("Batch job completed!"); } public static void main(Args _args) { // This method is used to create an instance of the batch class, prompt the user // for input using dialog, and then execute the batch job using run(). MyBatchClass batch = new MyBatchClass(); if (batch.prompt()) { batch.run(); } }
Under review
Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.
Congratulations to our 2026 Super Stars!
We are thrilled to have these Champions in our Community!
These are the community rock stars!
Stay up to date on forum activity by subscribing.
Giorgio Bonacorsi 710
André Arnaud de Cal... 465 Super User 2026 Season 1
Syed Haris Shah 317 Super User 2026 Season 1