how to solve unfortunately myapp has stopped????
Just think about this from my viewpoint for a moment.
You have something called myapp that has stopped. Do you know how many programs called myapp you can find on Google? Maybe this isn't even any of those, but something you wrote. I don't know if it's C<something>, Java, or whatever. I don't know if it's Windows, Mac, IOS, Android, Linux. I don't know what you were doing with the program or what input you may have provided. I don't know if it has a database and/or depends on an internet service.
And you think I can tell you how to solve it?
Guessing from the "MyApp" and the context and the error message that the OP is using Android Studio to develop an Android Application that is crashing. This is only an educated guess. OP, if true, see this link...
It's a pretty useless error message, but that's because it's intended to be seen by users, not developers. There is an un-displayed stack trace that may hold your answer, or at least part of it. Your app had an exception that wasn't handled somewhere and it "crashed". See the link above for details on how this all works and how to view it.
And James is correct. Details, details, details. All sorts of things could have caused this, so we can't say "You divided by zero on line 13" because you've given us none of those details. Find that stack trace and follow it.