Are you trying to save the pdf locally to the server or send it to the person?
It looks like you are trying to save the pdf to the server, in which case you can create a generate_pdf.rjs.js and have that file add a div to the page saying pdf generated correctly Sent from my Verizon Wireless BlackBerry -----Original Message----- From: adc <[email protected]> Date: Tue, 23 Jun 2009 03:54:14 To: ActiveScaffold : Ruby on Rails plugin<[email protected]> Subject: Generate PDF in action_links I created an action link with 1. config.action_links.add 'generate_pdf', :label=>"Stampa PDF", :type=>:record and i defined def generate_pdf pdf = PDF::Writer.new pdf.select_font("Helvetica") pdf.text("Ciao Ale") #pdf.text("Hello Ruby.HTML.it", 72, :justification=>center) pdf.save_as("public/example.pdf") end The pdf is correct but there is an error - ActionController::MissingTemplate (Missing template admin/dmwaters/ generate_pdf.html.erb but I would like to bring up the message "PDF Generate ok" like Error Message in active scaffold. Thanks for all --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "ActiveScaffold : Ruby on Rails plugin" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/activescaffold?hl=en -~----------~----~----~----~------~----~------~--~---
