Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

strange behavior between design time and run time

11 views
Skip to first unread message

Alex Liu

unread,
Apr 6, 2005, 6:06:18 AM4/6/05
to
Hi,

Please tell if i am in the wrong newsgroup.

What i am going to tell occurs rarely (several times in last year) but each
time it annoys me a lot. And it's annoying me NOW.

I wrote a project, which works fine so far. Then I want to add a public
member to a class and read by another class (the member is really simple -
say a boolean). I simply add the boolean, and in the read-class access the
value. Everything works fine in design-time in which code completion can
show me the new variable. I can build the executable as well.

However, when i run it, some strange behavior shown. The code seems not
getting the correct value. So I run into debug mode and access the
newly-added variable. And i get the following error msg:
"Error inspecting 'MyClass->new_variable': E2316 'new_variable' is not a
member of 'MyClass'"

I tried deleting all .obj files, .tds file, .~* files and made a full build
but it cannot solve the problem.

I tried creating a new project and add all my cpp and build it again but it
doesnt work /this time/. However, my teammate copy my project to his machine
and build it, the new variable can be accessed in debug mode (???). I copied
his updated project files (project.cpp, .bpr and .res) to mine and compiled
again but it fails.

But as i said this occurs rarely. At most cases this 'behavior' does not
occur.

I am using BCB6 on XP. Update patches applied.

Would anyone please tell me what's wrong with the program/IDE/etc? What
should i do now?

Thanks in advance.


Alex Liu

unread,
Apr 6, 2005, 6:08:53 AM4/6/05
to
one more test done.

I tried make a new project, add the modified class ONLY and try access the
new variable. It is ok.


Detlef

unread,
Apr 7, 2005, 6:52:41 AM4/7/05
to
Hi Alex,
sounds as if you have a problem with your header files ( but you said you
deleted all before you tested it again).
How complicated is your project. Do you use this class in different
projects? Maybe the header is included ( and compiled) in another file
(project).

My suggestion:
- don't use "precompiled headers"
- delete all temporary files
(*.bak;*.obj;*.csm;*.~*;*.#*;*.tds;*.dsk;*.res;.#*.*;*.ddp)
No real help, but ....
Detlef
www.seatec-gmbh.com

"Alex Liu" <ale...@hket.com> schrieb im Newsbeitrag
news:4253b4b5$1...@newsgroups.borland.com...

Mark Guerrieri

unread,
Apr 8, 2005, 2:07:34 PM4/8/05
to
Make sure there is not an older copy of the built project (dll, exe, etc) in
a different folder; I have had similar problems debugging dll's or bpl's
when an older version was in SYSTEM32 and the new version was somewhere
else...

Mark

"Alex Liu" <ale...@hket.com> wrote in message
news:4253b4b5$1...@newsgroups.borland.com...

Andrue Cope [TeamB]

unread,
Apr 11, 2005, 4:06:23 AM4/11/05
to
Can you trim your quotes, please or configure your newsreader so that
it doesn't append a copy of the message you're replying to below yours.

Thanks.

--
Andrue Cope [TeamB]
[Bicester, Uk]
http://info.borland.com/newsgroups/guide.html

Mark Guerrieri

unread,
Apr 11, 2005, 12:50:53 PM4/11/05
to
May bad- I usually do; I plead temporary stupidity...


0 new messages