Currently, we are developing the contents displayed in the Grid of the Form by CSV when clicking Menu Item Button from Add-On Form.
However, there are cases where only the selected lines are output as CSV, so (MultiSelectionHelper) is used to pass the information of the selected Form to the class that outputs CSV when the button is clicked.Also, "Onclicked" is used as the event when the button is clicked.
I would like to know specifically how to write the program.
Thank you very much.
Thanks to you I was able to solve the problem.
No it's not ok to write that and if you would try it you would notice a compiler error.
_args.caller().dataSource() returns a FormDataSource object, not a table buffer.
Also I had a mistake in my example, it's _args.record().dataSource(), not _args.caller().record().dataSource().
Anyway, here are some results for MultiSelectionHelper: www.google.com/search
And, when we combine everything we learned so far in this discussion, we will get something like this:
pubic static void main (Args _args) { FormDataSource fds = _args.record().dataSource(); MultiSelectionHelper msh = MultiSelectionHelper::construct(); msh.parmDataSource(fds); MyTable myTable = msh.getFirst(); while (myTable) { info(myTable.MyField); myTable = msh.getNext(); } }
Is it okay to write _args.caller().record().dataSource(). as "Table table = _args.caller().record().dataSource()"?
About MultiSelectionHelper, did you try to search any information in the web? There's plenty. Just let me know if you need me to find some article.
⇒
I would appreciate it if you could give me an article.
I mean the class that outputs the CSV. You don't need any "OnClicked" things anywhere. Simply a menu item button that points to your new class.
>In your new class you can access the caller form data source via _args.caller().record().dataSource().
⇒ In your new class. Is it an "Onclicked" class? Or is it a class that outputs CSV?
>Then you can launch MultiSeelctionHelper with this data source and fetch the records.
⇒I don't understand this yet.
In your new class you can access the caller form data source via _args.caller().record().dataSource().
Then you can launch MultiSeelctionHelper with this data source and fetch the records.
Is it now clear?
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.
As AI tools become more common, we’re introducing a Responsible AI Use…
We are honored to recognize Mansi Soni as our August 2025 Community…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
Sohaib Cheema 665 User Group Leader
Martin Dráb 595 Most Valuable Professional
Yng Lih 558