I\'m trying to use the scheduler for the first time to call a method:
protected function schedule(Schedule $schedule)
{
$schedule->call(\'M
You should not call controller methods this way. Controller methods are meant for handling HTTP requests.
The content of myMethodName should be pulled out into a command. You can learn about creating commands here.
That aside, the reason you're getting the ReflectionException is because of the exact reason the exception states: MyClassName is not a valid class.
$schedule->call('App\Http\Controllers\MyClassNameController@myMethodName')
The above specifies the Fully Qualified Name of the class you are trying to refer to. You could alternatively import that class at the top of your file and use a join
use App\Http\Controllers\MyClassNameController;
// ...
$schedule->call(join('@', [ MyClassNameController::class, 'myMethodName ]))
But again, you should not be calling controller methods this way.