Compiling problem, or is it?

  • Thread starter Thread starter Daniel Billingsley
  • Start date Start date
D

Daniel Billingsley

I have a solution consisting of 9 projects with various references to each
other (clean though, no loops, etc.). Visual Studio sometimes gives me
weird errors that it can't find one of the referenced assemblies, can't
write one, or now most frequently (almost 100% of the time): "A failure
occurred while attempting to start the compilation".

But in fact the compilation appears to have completed successfully. I've
got a freshly created exe and it runs just fine, even in debug mode from
within Visual Studio.

Before the errors have led to me to this KB article, but while the symptoms
were similar I've checked everything out and it doesn't seem to apply. (One
of the assemblies is 96k compiled.)
http://support.microsoft.com/default.aspx?scid=kb;en-us;313512

I also previously had this problem. It seems to be solved now, but maybe is
still somehow related:
http://support.microsoft.com/default.aspx?scid=kb;en-us;825007

Right now this is mostly a big nuissance, as everything usually works fine
in spite of the message. Sometimes I have to exit and reload VS to get it
to compile again, which is just getting really annoying.

Any suggestions?
 
Correction:

When I do a Rebuild Solution one of the assemblies is NOT rebuilt.

I deleted the .dll file from that project's debug subfolder of the obj and
bin folders. When I restarted VS I of course got a couple messages that it
couldn't find the assembly / dependency. Did Rebuild Solution. Everything
seems to have compiled, but VS still telling me it can't find the assembly.

Exited and restarted VS and the message is gone. Rebuild Solution and I'm
back to the "failure" message on the same assembly, and it's the only
assembly that didn't recompile.

For whatever it's worth, the assembly causing the problem is not the 96k
assembly, but it is referenced only by the 96k one. The 96k assembly also
references others.
 
I assume you've checked your build order, right?

I don't think there's any complete cure for this problem (but I'll be
watching in case someone knows better.) However, sometimes I've found that
when I can't "rebuild", I can "build". Then I usually get out of VS and come
back in. (Not that I have a reason for doing this, it's more like a
religious ritual that I perform whenever my build process needs to be
"cleansed.") After that, rebuild usually seems to work.

Hope this helps...
-Rachel
 
Yeah, the build order looks fine.

The problem is very consistent. If I do the steps I mentioned I get the
same results every time. I also have a consistent workaround in those
steps, but it's quickly becoming a major pain as it happens 100% of the time
now.
 
Daniel,
I always get this error but only when I am referencing projects whose dlls
are being used by a service currently running on the machine. Once this
service is stopped and a restart of the VS everything is all good.
Hope it helps in anyway.
--Landi
 
All 9 of the projects are used only in this solution. But there is
something weird going on along those lines (but it's something all within
the context of this solution). I say that because sometimes I have this
error and try to delete the dll in question so VS will rebuild it and I get
an error from Explorer that the files are in use. If I exit VS I can delete
fine.

So, it seems to be some weird locking situation from within VS itself, but
I've check the couple of KB articles and they don't seem to fit exactly or
solve the problem.
 
This is a little more than a nuissance. It's cutting my productivity
significantly.

I believe this is one of the MSDN managed newsgroups - shouldn't someone
from Microsoft be chiming in about now?
 
Daniel,
This is already 4 days old and I doubt it that anyone is going to look at
this anymore.
And I believe that Microsoft doesn't monitor this newsgroup, I could be
wrong though.
They have these MVPs that hare knowledgeable but don't get paid, because
Microsoft can't afford to pay them.

Good luck with everything
Landi
 
Landi said:
They have these MVPs that hare knowledgeable but don't get paid, because
Microsoft can't afford to pay them.

Ha! MS COULD afford to pay them for sure. MS is one of the richest companies
in the world. :)

Im not saying that they should pay MVP's - its just that your statement reads
quite funny.


--
Chad Z. Hower (a.k.a. Kudzu) - http://www.hower.org/Kudzu/
"Programming is an art form that fights back"

Develop ASP.NET applications easier and in less time:
http://www.atozed.com/IntraWeb/
 
It's one of the ones they're supposed to be monitoring for posts from MSDN
subscribers (which I am).
 
Daniel Billingsley said:
It's one of the ones they're supposed to be monitoring for posts from MSDN
subscribers (which I am).

I think that to be flagged by MS tech support, you need to post with
the right email address (I'm not sure if that's just your MSDN passport
address, or whether you need to register or something) and post via the
web interface. I could be wrong, of course...
 
Jon said:
I think that to be flagged by MS tech support, you need to post with
the right email address (I'm not sure if that's just your MSDN
passport address, or whether you need to register or something) and
post via the web interface. I could be wrong, of course...

yep, Daniel needs to register his "no spam" email address and post with
that, then he will get an answer to his posts. Instructions on how to
do this should be on his MSDN welcome pack letter. He won't need to
post via the web interface though, any newsreader will do.

Cheers Tim.
 
Yeah I know all that, and had it all set up properly apparently as I used to
get responses to my posts. From the MSDN site it LOOKS at first glance as
though they've changed the way that no-spam address is registered and maybe
they dumped my old registration.

I think I re-registered the address yesterday (it's not the same way I did
it a few years back so I'm not sure) and I figured I should eventually get a
response to these posts if I did it correctly.

Thanks guys. I'll just wait and see now.
 
Hi Daniel,

I was wondering if you ever managed to find a solution for this problem? I've got exactly the same issue and I'm stuck as to how to get round it...

Thanks,
Dylan
 
I fixed it !!

I was refefencing the same (not system) DLL in two of my projects with "local copy" set to false.
I made sure that "local copy" was set to true for both references and the error disapeared at last !!!

Hope it helps
 

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

Back
Top