Topic: Load Error on first line of Controller

Weird error any ideas would greatly help!

LoadError in MasterscreensController#index
Expected /home/cent285fall12/rails_apps/project1/app/controllers/masterscreens_controller.rb to define MasterscreensController

activesupport (3.2.8) lib/active_support/dependencies.rb:503:in `load_missing_constant'
activesupport (3.2.8) lib/active_support/dependencies.rb:192:in `const_missing'
activesupport (3.2.8) lib/active_support/dependencies.rb:190:in `each'
activesupport (3.2.8) lib/active_support/dependencies.rb:190:in `const_missing'
activesupport (3.2.8) lib/active_support/inflector/methods.rb:219:in `constantize'
activesupport (3.2.8) lib/active_support/inflector/methods.rb:218:in `each'
activesupport (3.2.8) lib/active_support/inflector/methods.rb:218:in `constantize'
activesupport (3.2.8) lib/active_support/dependencies.rb:554:in `get'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:69:in `controller_reference'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:54:in `controller'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:32:in `call'
journey (1.0.4) lib/journey/router.rb:68:in `call'
journey (1.0.4) lib/journey/router.rb:56:in `each'
journey (1.0.4) lib/journey/router.rb:56:in `call'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:600:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
rack (1.4.1) lib/rack/etag.rb:23:in `call'
rack (1.4.1) lib/rack/conditionalget.rb:25:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/head.rb:14:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/params_parser.rb:21:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/flash.rb:242:in `call'
rack (1.4.1) lib/rack/session/abstract/id.rb:205:in `context'
rack (1.4.1) lib/rack/session/abstract/id.rb:200:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/cookies.rb:339:in `call'
activerecord (3.2.8) lib/active_record/query_cache.rb:64:in `call'
activerecord (3.2.8) lib/active_record/connection_adapters/abstract/connection_pool.rb:473:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/callbacks.rb:28:in `call'
activesupport (3.2.8) lib/active_support/callbacks.rb:405:in `_run__167218171__call__4__callbacks'
activesupport (3.2.8) lib/active_support/callbacks.rb:405:in `send'
activesupport (3.2.8) lib/active_support/callbacks.rb:405:in `__run_callback'
activesupport (3.2.8) lib/active_support/callbacks.rb:385:in `_run_call_callbacks'
activesupport (3.2.8) lib/active_support/callbacks.rb:81:in `send'
activesupport (3.2.8) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (3.2.8) lib/action_dispatch/middleware/callbacks.rb:27:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/reloader.rb:65:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/remote_ip.rb:31:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/debug_exceptions.rb:16:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
railties (3.2.8) lib/rails/rack/logger.rb:26:in `call_app'
railties (3.2.8) lib/rails/rack/logger.rb:16:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/request_id.rb:22:in `call'
rack (1.4.1) lib/rack/methodoverride.rb:21:in `call'
rack (1.4.1) lib/rack/runtime.rb:17:in `call'
activesupport (3.2.8) lib/active_support/cache/strategy/local_cache.rb:72:in `call'
rack (1.4.1) lib/rack/lock.rb:15:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/static.rb:62:in `call'
railties (3.2.8) lib/rails/engine.rb:479:in `call'
railties (3.2.8) lib/rails/application.rb:223:in `call'
rack (1.4.1) lib/rack/content_length.rb:14:in `call'
railties (3.2.8) lib/rails/rack/log_tailer.rb:17:in `call'
rack (1.4.1) lib/rack/handler/webrick.rb:59:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
/usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:95:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `each'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:23:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:82:in `start'
rack (1.4.1) lib/rack/handler/webrick.rb:13:in `run'
rack (1.4.1) lib/rack/server.rb:265:in `start'
railties (3.2.8) lib/rails/commands/server.rb:70:in `start'
railties (3.2.8) lib/rails/commands.rb:55
railties (3.2.8) lib/rails/commands.rb:50:in `tap'
railties (3.2.8) lib/rails/commands.rb:50
script/rails:6:in `require'
script/rails:6

Controller

class Masterscreens < ApplicationController
  def index
    @masterscreens = Masterscreen.all
  end
end

Model

class Masterscreen < ActiveRecord::Base
end

Re: Load Error on first line of Controller

FOUND OUT THE ANSWER!!!

http://guides.rubyonrails.org/getting_started.html

There seems to be a discrepency with Gems 1.8.7 and Rails 3 + so it is absolutely necessary for
a person to upgrade to Gems 1.9.2 at the minimum. The above page will explain in further detail.

Because it was reading my code as being "old" I had to use rails command line to
create the controller for me. After that it was easy breezey.

Rails controller command

$ rails generate controller <name of desired controller>