From: Peter Szinek Date: 2007-11-20T19:05:58+09:00 Subject: Re: Dynamically call classes Tizian Taz wrote: > Hello, > > I'm new to Ruby but have got several years of experience with PHP. I > work on a project with several classes witch analyse text blocks. The > blocks begin with headers like "Status" or "Update" but that's not my > problem. > > I'd like to call classes dynamically like this : > > var = 'Status' > # and now I want to call the class "Status" > > How can I manage it? >> Kernel.const_get('Status') => Status cheers, Peter ___ http://www.rubyrailways.com http://scrubyt.org