Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 864
  • Last Modified:

getting VB6 compiler to show all errors - not just one

With the vb6 compiler - the default behavior is that when it encounters a compile error - it exits the compile process.

the problem with that is - if you've got 30 bugs - you have to compile, fix, compile, fix, compile, fix etc etc

I'm a C programmer - and in C - if there are 30 bugs - you can tell the compiler to continue compiling and report all the errors at the end.  Eg. lets say i change the name of a variable - it'll tell me all of the subsequent lines the old nonexistant variable name is used.

Is there a way of getting the vb6 compiler to behave like this?  or do i have to put up with compile, fix, compile, fix...
0
kenshaw
Asked:
kenshaw
  • 5
  • 3
  • 3
  • +4
1 Solution
 
Jim HornMicrosoft SQL Server Developer, Architect, and AuthorCommented:
None that I am aware of.  -Jim
0
 
PrestaulCommented:
You stated that perfectly:  "You have to compile, fix, compile, fix, compile, fix etc etc"
0
 
kenshawAuthor Commented:
are there any other vb6 compilers out there?
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
Harisha M GCommented:
Hi kenshaw,
   
You might be knowing an interpreter...

C/C++ use Compilers while VB uses Interpreter.

The only difference between compilers and interpreters is that the compiler will go through the whole code at once and reports all the errors. But the interpreter will scan one line at a time, compiles it and executes it if no error is found.

Bye
---
Harish
0
 
PrestaulCommented:
You could look at PowerBasic...  Strictly speaking it is not VB but almost exactly the same syntax.
0
 
Harisha M GCommented:
kenshaw,

Interpreter
___________
A program that reads source code one statement at a time, translates that statement to machine language, executes the machine language statement, then continues with the next statement. BASIC is sometimes interpreted and sometimes compiled. Although less convenient for programming, compilers are much faster than interpreters.

A high-level language translator that converts individual high-level computer language program instructions (source code) into machine instructions. It translates and executes each statement line-by-line during the running of the program.

Compiler
________
A software program that converts (translates) a complete software program written in high-level language SOURCE CODE (such as PASCAL or FORTRAN) into machine language. The entire source code is edited, compiled, and run at one time as compared to an INTERPRETER that is run one line at a time.

A program that reads source code, translates it into machine language, and writes the machine language to binary (object) code that can be directly loaded and executed.
0
 
Harisha M GCommented:
0
 
Erick37Commented:
In the Tools->Options... menu you have these options which makes bugs harder to find their way into your program:

[Editor tab] Check "Require Variable Declaration"
    This will force you to declare all variables before using them
[General tab] UnCheck "Compile on Demand"
    This will perform a full compile before running the application

Syntax errors are highlighted in red, so these kinds of errors do not make it to compile time.

0
 
amebaCommented:
In VB, you shouldn't use "Make EXE", use Ctrl+F5 (start with full compile) it doesn't make .obj files or link them, it is fast, and it goes directly to error.
After compiler finds the error:
- you can stop the application, correct the error and press Ctrl+F5 again to go to next error
- you can go to Break mode, correct the error and continue without starting compile again -  it's so called "Run - Edit - Continue" process; its productivity is much better than listing 30 errors (and clicking them).

VB6 uses the same optimizing compiler as C++.
0
 
amebaCommented:
Why are you giving C grade to everyone?
0
 
PrestaulCommented:
If you give a 'C' grade then you are calling his answer crap...  Take a look at the documentation.

http://www.experts-exchange.com/help.jsp#hi73

You should never give a 'C' grade without first asking for more clarification, and you should explain why you think the answer is only worth a 'C'.
0
 
Jim HornMicrosoft SQL Server Developer, Architect, and AuthorCommented:
Agreed.  The experts above provided answers that were technically correct to the question asked.  

The fact that it was not the solution that was asked for (namely, 'There isn't a way to do this for VB') should not be a factor in assigning a grade.

Awarding 'C' grades is usually motivation for experts not to respond to an asker's future questions.

Just my .02./experience.
-Jim
0
 
kenshawAuthor Commented:
The answer doesn't answer the question.

Also - the information was factually incorrect - there are vb compilers out there.

I am happy to give higher grades in future - but don't flame me just because you don't agree with the way i've categorised this answer.
0
 
Jim HornMicrosoft SQL Server Developer, Architect, and AuthorCommented:
>there are vb compilers out there.
Can you list them in this question?  The answer you accepted doesn't appear to address the original 'getting VB6 compiler to show all errors' question.
0
 
kenshawAuthor Commented:
the answer gave me the best short-term solution.  None of the answers answered the question.  One of my staff found a compiler - i'll get him to tell me what it is - but to be honest - this isn't exactly a high priority.
0
 
amebaCommented:
kenshaw,
> The answer doesn't answer the question.
> None of the answers answered the question.

I'll ask CS to remove points and grade.  If you are not happy with the answer, you don't have to accept it or award points.

Showing more than one error is possible, but very complicated and non-productive (for the stated reason - fixing the errors in IDE).
0
 
Jim HornMicrosoft SQL Server Developer, Architect, and AuthorCommented:
>One of my staff found a compiler - i'll get him to tell me what it is -
For reasons besides general amusement, I'd be interested in what your staff found.
0
 
Jim HornMicrosoft SQL Server Developer, Architect, and AuthorCommented:
Can you spell it out/provide a URL in this question?
0
 
moduloCommented:
PAQed with points refunded (500)

modulo
Community Support Moderator
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

  • 5
  • 3
  • 3
  • +4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now