Commented codes still affect the program

A

Allen

I have a problem; I hope someone can help me. I have MS Visual c++
studio.net 2003. I notice that the compiler is acting up. If I comment a
block of code (For example if I use // ..or /* .... */), this commented
block can still affecting the program. I have to delete or cut the whole
block of commented code in order to prevent such effect. I remember I had
the problem before and someone from this newsgroup helped me to fix it.
If I remember correctly he talked about something like out of Sync.
Thanks.
Allen
 
P

Patrice

Yes, IMO this is just that your last changed doesn't make it into the binary
file... Check for example the date/time of your build to check that it is
current. You likely run not what you just have build but some earlier EXE
file...
 
A

Allen

Thanks a lot Patrice
Your are right, but there is special procedure to solve this problem. May
be something has to be done to synchronize the binary and the others files
 
P

Patrice

It should just work. Do you have customized your build process ? Do you use
the proper EXE file (debug vs release) in case you don't launch from VS ? Do
you use the proper option on the various file (copy to the output directory)
? Precompiled header issue ? Does it produce this effect regardless of which
source file you have changed ? have you tried to rebuild all and restart
from there ?

A tool such as filemon from sysinternals could allow to check the file
activity and see where it fails or just check the archive (possibly on
google) to see if you find out the previous response you got...

I never had this problem myself...
 
A

Allen

HI Patrice,
I appreciate your efforts. There is some where we have to go and do some
setting. I went through this before.
 
L

Lloyd Sheen

Allen said:
HI Patrice,
I appreciate your efforts. There is some where we have to go and do some
setting. I went through this before.

Allen,

I remember that I had that problem many times on VS 2003. I have not
used it for years but is there a Clean menu item in the Project menu? If so
that is what I had to use to get past the problem.

Hope this helps
LS
 
A

Allen

Hi LS,
appreciate you answer,but

You said "is there a Clean menu item in the Project menu? "
I do not understand what you mean.

Please give more details
 
L

Lloyd Sheen

Allen said:
Hi LS,
appreciate you answer,but

You said "is there a Clean menu item in the Project menu? "
I do not understand what you mean.

Please give more details

I had problems with asp.net in VS 2003 leaving lots of "garbage" although it
never said what exactly it was. There is a method to "clean" out the files
created in previous builds. I don't have VS 2003 installed and haven't used
it for years but I remember one service pack added the command to clean the
project getting rid of those files and fixing the problem which seems to
have the source and the execution not in sync.

LS
 
A

Allen

Thank you Lloyd,

I have "clean" on the main menu, but it will not do any good. I notice
something else. When building the program and if there is an error, the
pointer on the left margin will point to the wrong line of code.
 
L

Lloyd Sheen

Allen said:
Thank you Lloyd,

I have "clean" on the main menu, but it will not do any good. I notice
something else. When building the program and if there is an error, the
pointer on the left margin will point to the wrong line of code.

One other thing you can check is that the source code file is saved when you
compile. Again I don't have VS 2003 but I think that is an option. If it
was not on then the compiler (which is only going to deal with saved files)
could be out of sync.

LS
 
A

Allen

Hi LS,

I am pretty sure that the file is saved. Because any changes that I made
will become valid in the next build.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,236
Members
46,822
Latest member
israfaceZa

Latest Threads

Top