function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Jonathan Wolff 7Jonathan Wolff 7 

Visualforce to Execute Apex

Hi I tried to create a javascript button, but I face some problems with it. Now I want to try it with a visualforce button. The apex execute action I want to trigger with the button is "XLSXGenerator.generate(new List<String>{});"

Could you give me an example of a visualforce with a button that executes this apex?
SwethaSwetha (Salesforce Developers) 
HI Jonathan,
Does the code from these links help?
https://github.com/RaymarMonte/apex-create-xlsx
https://salesforce.stackexchange.com/questions/130300/generate-xlsx-file-from-apex
https://salesforce.stackexchange.com/questions/84895/how-to-generate-an-excel-sheet-using-apex-code-such-that-the-excel-sheet-has-pro

If this information helps, please mark the answer as best. Thank you