Background color is not coming in report

Hi,
This is my input

<p><span style="color: rgba(255, 0, 0, 1)">Block</span> <span style="background-color: rgba(255, 0, 0, 1)">without</span></p>
and doing the builder.InsertHtml(inputString,true)
//true is set to keep builder formatting
But in the document downloaded color is not coming.

But if color code is rgb instead of rbga it is applying color.
But somehow my requirement is in rgba only. How can i make it work

@Amrinder_Singh
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): WORDSNET-25981

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.

PS: MS Word also does not handle rgba colors in HTML.

@Amrinder_Singh We have completed analysis of the issue. Aspose.Words’ document model doesn’t support colors that are not fully opaque and sets alpha value of all colors to 1. As a result, we cannot fully support rgba() and hsla() CSS functions. MS Word doesn’t support them either. We could implement this feature partially: only for scenarios where these functions specify opaque colors (alfa is set to 1), but this would confuse customers if Aspose.Words supported some rgba() and hsla() declarations and ignored others. So we are going to close the issue as Won't Fix.

ok @alexey.noskov Got it,
Thank you so much

1 Like

The issues you have found earlier (filed as WORDSNET-25981) have been fixed in this Aspose.Words for .NET 24.1 update also available on NuGet.