We experience an issue with the SVG generation from xlsx charts. Depending on the target framework the .svg file will be slightly different. This difference is enough to break functionality in other libraries when trying to use the svg file, including Aspose.Imaging when trying to convert it to a bmp file. The difference is also visual when looking at the two files.
<TargetFrameworks>net6.0</TargetFrameworks> => net6.0 target works - and file can be rendered/ converted correctly
<TargetFrameworks>net6.0-windows</TargetFrameworks> => net6.0-windows target does not work - and file can not be converted/rendered correctly
<TargetFrameworks>net48;net6.0-windows</TargetFrameworks> => net6.0-windows + net48 target does not work - and the file can not imported/rendered correctly
@licenselogimatic
We generated files under the frameworks net6.0 (Skiasharp) / net4 / net6-windows for comparison. Indeed, as you mentioned, there are differences in the generated files, as AsposeSVG.zip (40.1 KB)
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.
Issue ID(s): CELLSNET-57128
You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.
For the issues of differentiation, we have optimized the results as follows, which will take effect in version 24.11. CELLSNET-57128_241106.zip (61.3 KB)
The issues you have found earlier (filed as CELLSNET-57128) have been fixed in this update. This message was posted using Bugs notification tool by johnson.shi
Hi leoluo,
It appears that the issue still persists.
We tried with newer versions of Aspose and the error is still there. You can use the test project attached this thread and just update the nugget version.
Can you look into it and let us know what is the actual status?
I tested your scenario using the sample project (net6.0-windows) and the provided template file with Aspose.Cells for .NET v25.3 on Windows. It worked perfectly as expected. Could you clarify which specific target frameworks are causing issues? Additionally, please share the output SVG files generated for different frameworks (e.g., net4.0, net6.0, net6_skiasharp_linux, net6_skiasharp_windows, etc.) using Aspose.Cells for .NET v25.3. We will look into it soon.
Hi Amjad,
If for example you set the Target Framework to net6.0-windows or net48 it will not work. The demo project will generate an svg file and after will try to convert it to .bmp. If you look at the two images you will see that the bmp is a total failure. Now if you set the target Framework to net6.0 it will work.
At fault is the svg generator not the image converter. In our case we use a different library to handle the svg after but with the same results, it will only work if the target framework is net6.0 image.png (51.7 KB)
I do not involve other libraries and only use Aspose.Cells for .NET to render to SVG file which is fine tuned, see the output SVG targeted as net6.0-windows. Case6_6.zip (14.0 KB)
I suspect it is an issue with the process when you reconvert the generated (output) SVG (by Aspose.Cells) to BMP by other libraries.
The SVG file generated from Aspose.Cells looks good no matter if its build: net4.8, net8.0 or net8.0-windows. However if we save the generated SVG to a BMP file via Aspose.Imaging library, the generated file looks wierd using build net4.8 and net8.0-windows(works fine for net8.0). Also if we try to load the generated SVG file(from Aspose.Cells) into an external library called SVG then it will crash with an out of memory exception. Here like with Aspose.Imaging the external SVG library will fail if its build net4.8 and net8.0-windows but it works with net8.0. This is why we think there might be an error in the SVG generated from Aspose.Cells when build is net4.8 or net8.0-windows.
I have attached a project where you can see the issue. Please use data from “Case3”(should be set initially): AsposeSVG_Case3.zip (866.8 KB)
In Program.cs → line 94. We generate SVG file via Aspose.Cells.
In Program.cs → line 108. We create a BMP file from above SVG file(which seems to be broken).
In Program.cs → line 118. We try to draw an image from the SVG file as well but that call causes an out of memory exception.
Please tell me if you have any ideas why this occurs and also feel free to ask if you need any info about the sample project.
Thanks for the template file, sample app and details.
I tested the issue using your sample app with template file and noticed the issue. It seems by saving the generated SVG (by Aspose.Cells) to a BMP file via Aspose.Imaging library looks weird using build net4.8 and net8.0-windows.
We require detailed investigation of your issue. We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.
Issue ID(s): CELLSNET-58294
You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
More info
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising.
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
More info
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising.
Sets consent for sending user data to Google for online advertising purposes.