skip to Main Content

Newbee here. Trying to run the android emulator for the generic first_app flutter application.
Run flutter run -d windows

Receive:
C:DevelopmentFlutterfirst_app>flutter run -d windows
Launching libmain.dart on Windows in debug mode…
lib/main.dart(60,15): error G67247B7E: Expected ‘;’ after this. [C:DevelopmentFlutterfirst_appbuildwindowsflutterflutter_assemble.vcxproj] C:Program FilesMicrosoft Visual Studio2022CommunityMSBuildMicrosoftVCv170Microsoft.CppCommon.targets(247,5): error MSB8066: Custom build for ‘C:DevelopmentFlutterfirst_appbuildwindowsCMakeFiles13756e3632117b79f6e0bc292bc438e0flutter_windows.dll.rule;C:DevelopmentFlutterfirst_appbuildwindowsCMakeFilesf154f6c681490929a1ff6491e40cd6b3flutter_assemble.rule’ exited with code 1. [C:DevelopmentFlutterfirst_appbuildwindowsflutterflutter_assemble.vcxproj] Building Windows application…
Exception: Build process failed.

Other information:
Flutter Doctor is clean. That took hours.
Running from Android Studio works.
Launching emulator works correctly
Have tried Flutter Clean, Flutter upgrade, Flutter Master.
Have tried running from powershell with the same error.

Any assistance welcomed.

2

Answers


  1. Chosen as BEST ANSWER

    All, on a whim, I deleted my first_app and created it again via flutter create first_app. Immediately running flutter run, it works!


  2. First you can check if the emulator is running or not by this command

    flutter devices            
    

    Then you can directly run your app through

    flutter run -d device-id
    

    In my case, it was

    flutter run -d emulator-5554   
    

    devices

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search