Article Discussion
Creating Printable Documents with Ruby
Summary: In this article, Austin Ziegler introduces the creation of a variety of types of documents with PDF::Writer for Ruby. This introduction covers basic creation, partial document generation and customization, and Rails-generated documents.
24 posts on 2 pages.      
« Previous 1 2 Next »
The ability to add new comments in this discussion is temporarily disabled.
Most recent reply: December 1, 2008 4:33 AM by Gustavo
Rudy
Posts: 1 / Nickname: rudisoe / Registered: April 15, 2007 10:09 PM
Re: Creating Printable Documents with Ruby
April 16, 2007 3:16 AM      
I have this strange newbie problem with pdf::Writer in Ruby on rails. (MacOSX, MAMP, Locomotive, TExtmate)

I took the first example out of the article, and it does actually saves the file, but... NOT to the desktop, but to the railsrootdirectory. Whatever I try, I can't get it to download it to the desktop, and I cannot find an explanation how to get the files there. Without it, the whole idea of pdf::writer seems a bit lost to me.
Could someone help me out here?
Many thanks inb advance.
Rudi
wai
Posts: 1 / Nickname: kevinwai / Registered: April 24, 2007 4:18 PM
Re: Creating Printable Documents with Ruby
April 24, 2007 9:22 PM      
Hi,

I am new to ruby and right now I am trying to do an export of a HTML table to a pdf file.

Firstly, I have a dynamic data in the table whereby user needs to select different drop down lists and send the values to the back end to query the database and display the result. I am using ajax to do this.

However, I still don't know how to create a pdf file of a HTML table.

Can anyone help me with this?

Thanks.
franz
Posts: 2 / Nickname: practor / Registered: June 27, 2007 6:51 PM
Re: Creating Printable Documents with Ruby
June 28, 2007 0:40 AM      
I'm trying to do the Marshal dumping and loading. Everything works fine from my Rails console but I get the error message "dump format error" via the web browser. Any ideas why?

Thanks in advance,
Franz
franz
Posts: 2 / Nickname: practor / Registered: June 27, 2007 6:51 PM
Re: Creating Printable Documents with Ruby
June 28, 2007 2:05 AM      
For some reason I haven't figured out yet, the dump formats differ when dumping from the console and from within my rails app. I did the dump from my rails app and used that as my template and now all is working as it should.

Thanks for making such a useful PDF tool for ruby.

Kind regards,
Franz
bbb
Posts: 1 / Nickname: railspdf / Registered: July 11, 2007 0:55 AM
Re: Creating Printable Documents with Ruby
July 11, 2007 6:58 AM      
hi everyone,
I used the pdf ::writter , it's very good . but I want to create the pdf page basing on the rhtml page that what's I don't know how because I don't want to recreate the queries and all the tests that I used to get the .rhtml page. what I want really is that I can from my page.rhtml and with cliking on the link pdf ,generate a pdf pge that contain the same information as the.rhtml
can u help
thanks
ricardo
Posts: 2 / Nickname: ricardo85x / Registered: June 2, 2008 3:32 AM
Re: Creating Printable Documents with Ruby
June 2, 2008 8:40 AM      
Hi

I want to create a TAG for changing the text color like that:


pdf.text("name: <c:color text='Green'> Robert </c:alink> ")

but it is so hard to make.

Some one know to do that or know if there is a way to change the color of a string like take(with tags)
ricardo
Posts: 2 / Nickname: ricardo85x / Registered: June 2, 2008 3:32 AM
Re: Creating Printable Documents with Ruby
June 2, 2008 8:41 AM      
Hi

I want to create a TAG for changing the text color like that:


pdf.text("name: <c:color text='Green'> Robert </c:color> ")

but it is so hard to make.

Some one know to do that or know if there is a way to change the color of a string like take(with tags)
Orthon
Posts: 1 / Nickname: markeb / Registered: August 22, 2008 2:58 AM
Re: Creating Printable Documents with Ruby
August 22, 2008 8:07 AM      
hi

i have a weird PDF generation, i have to make a report and to do it i create various dinamic tables, but when i create the pdf in the first page tables apear normal, on the second apears the heading of column and in the next pages one column per page (the name of the column) after all column names apear the tables go normal and no more column names apear....

can anyone help im cainda new on ruby and this its driving me crazy

thamks
Gustavo
Posts: 1 / Nickname: gdelfino / Registered: November 30, 2008 10:24 PM
Re: Creating Printable Documents with Ruby
December 1, 2008 4:33 AM      
I need to open an existing PDF file and add some text to it. Is this possible using PDF::Writer?
24 posts on 2 pages.
« Previous 1 2 Next »