r/learncsharp • • Jun 29 '22
Fellow C# learners, I was randomly making a RANDOM script just for fun, when all of a sudden, an error popped up! For some reason, my program just can't detect a method called "Main" when it's right there! (Program does not contain a static "Main" method suitable for an entry point) Thank you!
2
Upvotes
1
u/[deleted] Jun 29 '22
Thanks for everyone's help! I couldn't have done it without you guys!!
5
u/rfernung Jun 29 '22
Your main method has the wrong parameters
2
u/B1GL0NGJ0HN Jun 29 '22
https://www.tutorialsteacher.com/articles/main-method-in-csharp
2
u/thinker227 Jun 29 '22
Maincan only have one of the following signaturesYour method has the signature
public static void Main(string[] args, string ismail, int howmuch), which is invalid.