'Need help to migrating flutter project to another device

I want to migrate my flutter project to my new pc, the android studio and flutter are all set in the new pc. If I make a new flutter project, it works fine, however, if I open the project from my old PC, It cannot detect the flutter library. Any suggestions?

enter image description here

Flutter doctor result enter image description here



Solution 1:[1]

Use this command

flutter clean

flutter pub get

flutter packages get

flutter packages upgrade ( Optional - use if you want to upgrade packages )

Restart Android Studio or VS Code

Hopefully the problem will be solved.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Md Nezam Uddin