Bug in file ExcelPicture.cs

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

Hi,

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

Coordinator
Jan 24, 2010 at 7:03 AM

Hi,

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 :)

Jan