flutter The method ‘File.create’ has fewer named arguments than those of overridden method ‘File.create’

Solution 1:

I kept getting the same error, But I solved it adding by adding
file: ^6.1.4 in my dependencies

If you are having the same problem. Make sure you have the latest file dependency.

Solution 2:

If file wasn’t one of your dependency. Just run the below command to upgrade transitive dependencies

flutter pub upgrade

This will update all packages to latest compatible versions. And file may be updated as well to latest version.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)