What does the following error mean- No Scaffold widget found?

157

The error says that you have no Scaffold widget in your code. Put a Scaffold widget in your code and the error will be gone.

Your code (probably) will be like this:

body: //code

Instead of this, it should be like this:

return Scaffold( body: //code )

Share:
157
Dendimuhmd
Author by

Dendimuhmd

Updated on January 04, 2023

Comments

  • Dendimuhmd
    Dendimuhmd over 1 year

    even i try to get alert dialog, this message always come

    Error dialog

    • Yash Kadiya
      Yash Kadiya about 2 years
      try wrapping your widget with Scaffold.
    • phuzi
      phuzi about 2 years
      Try adding the error as text to the question. Please show us your (relevant) code and what you have tried in an effort to resolve the error.