blog community
Silverlight: ImageError error #4001 AG_E_NETWORK_ERROR

Ah yes the dreaded error #4001. I ran into this problem and every solution Google presented to me did not work. So what’s the situation: I have some images in my Silverlight project with Build Action set to Content. As a result the image is put into the .xap. With my development background I put these images in subfolders in the project as can be seen in the image.   The image source property is set to /80 – Resources/10 – Images/ContentImage.png. And this situation resulted in the error.

It turns out that Silverlight breaks because there are spaces in the folder names (the spaces around the dash). When I remove these spaces (in the project folder structure), the error is gone! NB when hosting the image on the webserver (with your .xap for example) spaces in folder names are no problem at all.


Posted 26-06-2009 23:48 by Jos van Dixhoorn
Filed under:

Comments

Patrick Bélanger wrote re: Silverlight: ImageError error #4001 AG_E_NETWORK_ERROR
on 26-08-2009 21:03

Great tip !  Just saved my sanity.  Love Silverlight, but could do with more explicit exception messages.

Thanks again !

Add a Comment

(required)  
(optional)
(required)  
Remember Me?
Enter code (required)
Powered by Community Server (Commercial Edition), by Telligent Systems