I had a strange problem the other day when using
Intellisense, and wondering if anyone has any experience
with or advice on this...
Just to give some quick background, I have a multi-tier
application, with business objects coded in a business
layer (C# project), the service interfaces and service
objects coded in two C# projects, respectively.
In my service objects project, I go to call on one of the
business object function in the usual way, create an
instance of the class, and then call the function. As I
type after the period, Intellisense drops down through the
functions, and when I press the "(" to autocomplete the
entry, Visual Studio locks up... Every time.
The lockup occurs even if I type out the whole function
name, and even if I work around it to keep Intellisense
from popping up, if I then go back to edit the function
arguments, it again locks up if I do something that causes
the Intellisense tooltip for the function to pop up.
The only two functions that do this are two new functions
that i added to the business class (both at the same
time.) None of the other fnctions do this. I was able to
work around the problem by going back to the business
class, and changing the names of the two functions and
rebuilding. However, when I then changed them back to
their original names, the problem came back. There was
nothing especially strange about the original function
names.
I do have a sort of "theory" about what's happened here,
but not sure how to fix it. For those of you who remember
Visual studio 6, sometimes the ClassWizard would get
corrupted, and you'd have to delete it's .NCB file in the
project to fix it or, in some cases, go an maually edit
the entries in the .CLW (I think) file to "fix" the
ClassWizard's associations with the files and classes in
your program if you really screwed things up. Perhpas
there is something like this going on heer? My theory is
that "somehow" "some file" in the project has "something"
invalid in it about my two new functions. Whatever this
invalid data is, it's causing the environment to lock up
whenever Intellisense encoutners the bad data. When I
change the names of the functions, Intellisense no longer
encounters the bad data, hence the problem goes away.
However, beacuse the data for the function entries in this
hypothetical table is invalid, their entries are not being
erased when I change the function's names (and
therefore "remove" them.) Hence, when I change the
functions back to their original names, they again become
associated with their invalid data.
My first inclination would be to simply delete the project
and re-create it, adding back in all the files. However,
this is a HUGE project, integrated with a system in
production, and is tied in to source control, and I could
really see myself maknig a big project out of this if I go
screwing with the project and it's references and all that.
It is very frustrating to encounter things like this. I
am usually the one to whom everyone turns for solutions
for this that and the other thing, but so often, I seem to
have trouble finding the solutions to "my" issues. Any
help would be greatly appreciated on this. Thanks!
-- Jim
PS - Please also see my other post about Intellisense and
the tooltips. I would really appreciate info on that one
as well.