With Spire.Doc Free Edition, version 6.3.0.41040 we are testing document conversion capability, from doc to PDF.
With this code :
newDoc = New Spire.Doc.Document
newDoc.LoadFromFile(conv.DocPath, FileFormat.Auto)
newDoc.JPEGQuality = conv.JpgQuality
newDoc.SaveToFile(conv.PDFPath, FileFormat.PDF)
newDoc.Close()
we got this kind of exception:
System.ArgumentException: '-64' non è un valore valido per 'red'. 'red' deve essere maggiore o uguale a 0 e minore o uguale a 255.
in System.Drawing.Color.CheckByte(Int32 value, String name)
in System.Drawing.Color.FromArgb(Int32 alpha, Int32 red, Int32 green, Int32 blue)
in sprᣗ.ᜀ(Color A_0, Color A_1, Single A_2)
in sprᣗ.ᜁ(TextureStyle A_0, Color A_1, Color A_2, RectangleF A_3)
in sprᣗ.ᜁ(TableCell A_0, sprᾺ A_1)
in Spire.Doc.TableCell.Spire.Doc.Layout.IDocumentBase.Draw(sprᣗ dc, sprᾺ ltWidget)
in sprᾺ.ᜀ(sprᣗ A_0)
in sprᾺ.ᜀ(sprᣗ A_0)
in sprᾺ.ᜀ(sprᣗ A_0)
in sprᾺ.ᜀ(sprᣗ A_0)
in sprᾺ.ᜀ(sprᣗ A_0)
in sprᶌ.ᜀ(sprᣗ A_0)
in sprṕ.ᜀ(Int32 A_0, Int32 A_1, ImageType A_2, MemoryStream A_3, Boolean A_4, Boolean A_5, Boolean A_6)
in spr.ᜀ(sprṕ A_0)
in spr.ᜀ(Document A_0)
in Spire.Doc.Document.ᜂ(String A_0)
in Spire.Doc.Document.SaveToFile(String fileName, FileFormat fileFormat)
in DocDaServizi.clsDocDaServizi.ConvertDocToPDF(Dati_tabConversioni& conv, Exception& e) in D:\Progetti\xData\CSI\GesLabNet\GesLabNet\DocDaServizi\clsDocDaServizi.vb:riga 577
The problem seems to be the background colour of the first row of the table, currently is RGB(223,223,223), if we change to RGB(217,217,217) everything works fine. But we have hundreds of documents and we can not edit them all.
Any suggestion?
Kind Regards