Sunday 9 March 2008

'System.IO.FileNotFoundException' while loading from Resource File (Pocket PC)

You get this exception when u try to read a bitmap from a resource file in compact framework. Even though the app. works fine, the exceptions can scare you , as it did for me, it seem to puzzle me and constantly psyched me, making me feel that i was doing something terribly insane ,therefore challenging my intellect.

A first chance exception of type 'System.IO.FileNotFoundException' occurred in mscorlib.dll
A first chance exception of type 'System.IO.FileNotFoundException' occurred in mscorlib.dll
A first chance exception of type 'System.UnauthorizedAccessException' occurred in mscorlib.dll




After painstaking analysis and innumerable Google searches i find the problem was with the CF CLR . the CLR tries to load two satellite assemblies and fails before it loads them from the current assembly (manifest resource). It's actually an issue with the .NET CF and the bug can be found here. Hmm, now i can go to bed peacefully..CF Team kiss my chaddees , bloddy hell innit?

No comments:

Post a Comment