11

Could not open file

I have an existing flutter project, which coded with VS Code. Now I want to open it from Xcode to do some configurations in Runner.xcworkspace. But it was unable to open the project from Xcode and it shows the above warning. So, how can I open my existing project from Xcode now?

Chanaka N. Bandara
  • 247
  • 1
  • 3
  • 10
  • You can delete all pod related autogenerated files(podfile.lock, Pods folder, Runner.xcworkspace), Then run "flutter pub get" and "pod install" from ios/ path. It will generate all the deleted files again. Now try to open it. It should work. If still not, then something wrong with XCode. Please have a look here, https://developer.apple.com/forums/thread/120972 – shuvo Oct 06 '21 at 12:24

4 Answers4

23

If you want to make changes in the Runner.xcworkspace and you are using VSCode, I would suggest you open the project in VSCode and Right-Click on the ios folder.

Here you will see an option: Open in Xcode.

Select that option and the iOS project of the Flutter project will open in Xcode and you can carry on with the changes as you want

One thing to note is that like Android Studio, Xcode is not supported for Flutter Development as of now so if you try to open the whole project it will not let you.

Saheb Singh
  • 1,172
  • 7
  • 13
9

Note! Unlike Android studio, flutter isn't supported to XCode yet, you have to open iOS folder of Flutter project only and solely.

1- Open XCode

2- Select 'Open existing Projects'

3- Search your project through search bar in window or search manually through directory.

4- From your Flutter Project, open the iOS folder.

And here we go! You have opened it.

Bilal Saeed
  • 2,092
  • 8
  • 31
6

I successfully open the AppFrameworkInfo.plist file with Xcode as follows.

  1. Open the project with Android Studio
  2. Select the iOS > Runner folder
  3. Navigate to Tools > Flutter > Open iOS Module in Xcode
Chanaka N. Bandara
  • 247
  • 1
  • 3
  • 10
0

How I solved,I deleted the Ios folder and then runflutter create . and then just change and add what you want.

samad shukr
  • 561
  • 7
  • 15