Forum: Ruby Need help

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
A4473e126671d44103876220f5712b24?d=identicon&s=25 Aaron (Guest)
on 2007-05-12 04:05
(Received via mailing list)
I got this error in Ubuntu when i wanted to use parseexcel .
Here is the code :
 require 'parseexcel'

 workbook = Spreadsheet::ParseExcel.parse("12.xls")
 worksheet = workbook.worksheet(0)
 ......

The full error message:"test.rb:1:in `require': no such file to load
-- parseexcel (LoadError)        from test.rb:1 "

Really wanna your help, thanks!
Caf38c89d40443a858741b61ac6d82de?d=identicon&s=25 Dan Zwell (Guest)
on 2007-05-12 05:19
(Received via mailing list)
Aaron,

In the future you'll have better luck if you title your posts
descriptively.

Ruby is looking for the 'parseexcel' include file and can't find it. Do
"locate parseexcel.rb" to see whether it is installed at all. If not, do
"gem install parseexcel" to install the gem. If you do locate the file,
it means it's in the wrong directory and you need to tell ruby where to
look for libraries:

$ ruby -I /my/include/dir/ruby/gems/1.8/gems     test.rb

Good luck,
Dan
1f3a6a6fe37acbb0dfee9580c1e48afe?d=identicon&s=25 Armando Padilla (Guest)
on 2007-05-12 16:30
(Received via mailing list)
Aaron havent tried replicating this issue but are you sure you have
the library parseexcel installed?
Feee221f9eb7818d90625ea141bfd60c?d=identicon&s=25 bbiker (Guest)
on 2007-05-13 22:52
(Received via mailing list)
On May 11, 11:19 pm, Dan Zwell <dzw...@gmail.com> wrote:
> $ ruby -I /my/include/dir/ruby/gems/1.8/gems     test.rb
>
> >  workbook = Spreadsheet::ParseExcel.parse("12.xls")
> >  worksheet = workbook.worksheet(0)
> >  ......
>
> > The full error message:"test.rb:1:in `require': no such file to load
> > -- parseexcel (LoadError)        from test.rb:1 "
>
> > Really wanna your help, thanks!- Hide quoted text -
>
> - Show quoted text -

did you install parseexcel manually using the tarball or via
automatically via gem install parseexcel?
This topic is locked and can not be replied to.