I am invoking vbc compiler via my code.

However I am getting this error :- vbc : error BC31011: Unable to load referenced library X: Access is denied. C:\Core\FinalCode\X.dll : error BC31011: Unable to load referenced library 'C:\Core\FinalCode\X.dll': Access is denied. vbc : Command line error BC2010 : compilation failed : '0xC0000005'

The same code works when I call the vbc compiler from command-line.

This problem is only occuring with one dll. All permissions are there on the dlls. Also all dlls are strong-named.

Can somebody help me ?