This project has moved and is read-only. For the latest updates, please go here.

Bug in file ExcelPicture.cs

Jan 22, 2010 at 5:40 PM
Edited Jan 22, 2010 at 5:41 PM


Great work you've done here man.

I've found a bug in file ExcelPicture.cs on line 112.

This code

     UriPic = GetNewUri(package, String.Format("/xl/media/image{0}.{0}", imageFile.Extension));

should be replaced with this code

     UriPic = GetNewUri(package,

"/xl/media/image{0}." + imageFile.Extension);

This is causing an infinite loop in function GetNewUri() when adding a new picture from a FileInfo object.

Best Regards,

Orlando Azevedo

Jan 24, 2010 at 8:03 AM


Thanks for the feedback!

I have been working on this code lately so i think I've fixed the bug. I'll have a look at it when I get back home.

I'll try to check it in tonight. By the way, I hope I can do a new release this week, so if you have time, please test your project with the new source.

I've added a new sample 6, that shows a little bit more of the stuff you can do :)