"error CS1577: Assembly generation failed -- Unexpected exception processing attribute -- System.Arg

G

Guest

Some time ago I installed VC# 2003, made a small generic project, compile
with the allow unsafe flag and I get the error below:
"error CS1577: Assembly generation failed -- Unexpected exception
processing attribute -- System.ArgumentException: Invalid directory on URL."

(If I do not compile with the unsafe flag compiler setting all compiles
perfect)

After long tracing, I ended up discovering that it is csc.exe installed by
the .NET framweork 1.1 that generates this error.
When I compile this with the C# 2002 (and csc.exe from .NET 1.0) then I do
not get this message, with or without unsafe compiler option..

I still have no fix for this and I need it because I have to move to vc#
2003.
So can anyone give some tips in order to trace back WHAT attribute is giving
me problems and where I can find it?

I am using Windows 2000 professional with all the critical updates and
service packs installed.
Propably some stupid setting that are missing, but which one????
 
G

Guest

Some time ago I installed VC# 2003, made a small generic project, compile
with the allow unsafe flag and I get the error below:
"error CS1577: Assembly generation failed -- Unexpected exception
processing attribute -- System.ArgumentException: Invalid directory on URL."

(If I do not compile with the unsafe flag compiler setting all compiles
perfect)
I just uninstalled the .NET framework and reinstalled it, and it got worse.
I also get this error when I do ot use the /unsafe switch from csc.exe. :-(

The big question now: Is there any chance that the csc.exe itself or some
used dll's by it, that gets into conflict with the .NET security?
Anyone knows what to check?
 
G

Guest

Some time ago I installed VC# 2003, made a small generic project,
compile
I just uninstalled the .NET framework and reinstalled it, and it got worse.
I also get this error when I do ot use the /unsafe switch from csc.exe.
:-(

Only one machine has this problem and it happens to be my development
machine (tested with the same code).
All other computers have no problems, with this csc.exe. This is clearly
some crash in the .NET v1.1 csc.exe, but I have no idea what causes it.
It is related to the unsafe compiler option, maybe it is deeper and at the
level of the CLR?

I reinstalled VC# many times, also uninstalled+reinstalled, repaired,
installed .NET 1.1, uninstallerd+reinstalled....
Probably some silly path or environment variable that is incorrect, if only
I know how to find which one? Any tips are welcome.
Any tips how to debug this csc.exe to trace the problem would also be
welcom.

Here is an example of what I get.

-----------
D:\Source\Scratch\DICOM\Managed\WindowsApplication1>csc form1.cs /unsafe+
Microsoft (R) Visual C# .NET Compiler version 7.10.3052.4
for Microsoft (R) .NET Framework version 1.1.4322
Copyright (C) Microsoft Corporation 2001-2002. All rights reserved.

error CS1577: Assembly generation failed -- Unexpected exception processing
attribute -- System.ArgumentException: Invalid directory on URL..

D:\Source\Scratch\DICOM\Managed\WindowsApplication1>

------------
D:\Source\Scratch\DICOM\Managed\WindowsApplication1>csc form1.cs /unsafe-
Microsoft (R) Visual C# .NET Compiler version 7.10.3052.4
for Microsoft (R) .NET Framework version 1.1.4322
Copyright (C) Microsoft Corporation 2001-2002. All rights reserved.


D:\Source\Scratch\DICOM\Managed\WindowsApplication1>
 
G

Guest

We have a break through in this problem:

I removed every Microsoft compiler, and only reinstalled VC# 2003 and I have
a completely new error.
Maybe this is the real cause, the big question what does it mean? I do not
have a XML input file or so.
The new error:

error CS1577: Assembly generation failed -- Unexpected exception processing
attribute -- System.ArgumentException: Unable to generate permission set;
input XML may be malformed..
 
G

Guest

YES!!!!! I got it!!!!
It was the WINDIR environment variable, all is functioning perfect now!
 

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

Top