Linked Questions

Popular Questions

I have a list of items and i want when the user click on an item, appear another window, i write the code as shown bellow

return ListTile( leading: Container(
 padding: EdgeInsets.only(left: 8.0 , top: 8.0 ,bottom: 8.0),
 child: Column(
   children: <Widget>[
     _buildGymLocationRow(gym), // method 
      SizedBox(height: 5.0,),
     _builDescrRateRow(gym), ], ), )

,onTap: (){ Navigator.push( context, new MaterialPageRoute(builder: (context) => new gymDetails()));
},
);

but when i click on the item or ListTile, it's show me this error.. i don't know what i have to do.. please I need help

I/flutter ( 9134): Another exception was thrown: NoSuchMethodError: The method 'ancestorStateOfType' was called on null.

Related Questions