Click here to Skip to main content
16,020,162 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
the error message says there were buid error.do you want to continue and run the last successful build


What I have tried:

I added 3 forms in the first form, I programmed a button and typed these codes "this.Hide();
 form2 frm=new form2();
frm.show(); " and in the second form I programmed another button and I typed these codes"Application.OpenForms[0].show();
this.close(); " and when I run the error message appears
Posted
Updated 30-May-22 1:56am
Comments
CPallini 30-May-22 7:30am    
Look better at the error produced, it contains full details (of your failed build).
You could also post here the complete and exact error message.
Killua Zoldyck 2022 30-May-22 8:21am    
I can't find the error because before I run, it is written"no issues found "
0x01AA 30-May-22 7:32am    
c# is case sensitive. So use Show() and Close()

1 solution

0x01AA is right and has probably solved your problem, but ... you should expect to get syntax errors every day, probably many times a day while you are coding - we all do regardless of how much experience we have! Sometimes, we misspell a variable, or a keyword; sometimes we forget to close a string or a code block. Sometimes the cat walks over your keyboard and types something really weird. Sometimes we just forget how many parameters a method call needs.

We all make mistakes.

And because we all do it, we all have to fix syntax errors - and it's a lot quicker to learn how and fix them yourself than to wait for someone else to fix them for you! So invest a little time in learning how to read error messages, and how to interpret your code as written in the light of what the compiler is telling you is wrong - it really is trying to be helpful!

So read this: How to Write Code to Solve a Problem, A Beginner's Guide Part 2: Syntax Errors[^] - it should help you next time you get a compilation error!
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900