0

i created a new module, after runing this command

php bin/magento module:enable myFirstModule

i am getting this error.

Fatal error: Uncaught ReflectionException: Class Magento\Framework\App\ResourceConnection\Proxy does not exist in C:\xampp\htdocs\magento2\vendor\magento\framework\Code\Reader\ClassReader.php:19 Stack trace: #0 C:\xampp\htdocs\magento2\vendor\magento\framework\Code\Reader\ClassReader.php(19): ReflectionClass->__construct('Magento\Framewo...') #1 C:\xampp\htdocs\magento2\vendor\magento\framework\ObjectManager\Definition\Runtime.php(44): Magento\Framework\Code\Reader\ClassReader->getConstructor('Magento\Framewo...') #2 C:\xampp\htdocs\magento2\vendor\magento\framework\ObjectManager\Factory\Dynamic\Developer.php(48): Magento\Framework\ObjectManager\Definition\Runtime->getParameters('Magento\Framewo...') #3 C:\xampp\htdocs\magento2\vendor\magento\framework\ObjectManager\ObjectManager.php(70): Magento\Framework\ObjectManager\Factory\Dynamic\Developer->create('Magento\Framewo...') #4 C:\xampp\htdocs\magento2\vendor\magento\framework\ObjectManager\Factory\AbstractFactory.php(144): Magento\Framework\ObjectManager\ObjectManage in C:\xampp\htdocs\magento2\vendor\magento\framework\Code\Reader\ClassReader.php on line 19

i have clear all of my cache and also used upgrade command. but in CMD the results are...CMD Results

what would be the reason of this?enter image description here i also removed those module files but still there is error.

  • You can supply your module code? – tokey Aug 20 at 6:12
0

You should consult magento devdocs in order to learn how to create module and its naming conventions,http://devdocs.magento.com/guides/v2.1/architecture/archi_perspectives/components/modules/mod_conventions.html. you will also find other sites too.

Secondly, first you need to disable your module from command line php bin/magento module:disable ModuleName then delete your generated/code folder and run php bin/magento setup:upgrade and php bin/magento setup:di:compile commands.

Hope it will fix your issue.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.