Problem with to list the data's in a list box

hi,

i got the answer when i user the panel table for the list boxes. but
when i have to use Demogaphic_categories table. if i use this it shows
the error in

Expected ./app/models/demographic_category.rb to define
Demographic_category

Like this.

dataBase name is - Demographic_categories

fields - id, name, allow_multiple

my coding:

index.rhtml

<%= collection_select(‘object’, ‘method’, @demographic_categories, :id,
:name, {},
{:multiple => ‘multiple’}) %>

in controller:

@demographic_categories=Demographic_category.find(:all);

can u tell this what's the error in this? please

You need demographic_categories as the table name and
DemographicCategory as the model name.

hi,

thanks for ur reply. yes i have the demographic_category table and
model name. i rellay don’t know still why its not working.

Mick S. wrote:

You need demographic_categories as the table name and
DemographicCategory as the model name.

hi,

my error is

Expected ./app/models/demographic_category.rb to define
Demographic_category

but i have the Demographic_category model. i don’t know why is not
working?

Mick S. wrote:

What error message are you getting now?

What error message are you getting now?

hi,

i got the answer.

ROR wrote:

hi,

my error is

Expected ./app/models/demographic_category.rb to define
Demographic_category

but i have the Demographic_category model. i don’t know why is not
working?

Mick S. wrote:

What error message are you getting now?

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs