Spire.Office

Spire.Office 4.4.0 is released

We're pleased to announce the release of Spire.Office 4.4.0. This version has added some new features, for instance, Spire.PDF supports finding and highlighting text crossing lines, Spire.Presentation supports applying animation to text, Spire.XLS supports setting the inner margins of a textbox, and Spire.Spreadsheet supports customizing language configuration path. Besides, numerous bugs have been fixed by this update.

In this version, the most recent version of Spire.Doc, Spire.PDF, Spire.XLS, Spire.Presentation, Spire.Email, Spire.DocViewer, Spire.PDFViewer, Spire.Spreadsheet, Spire.OfficeViewer, Spire.Dataexport, Spire.Barcode are included.

  • Spire.Doc.dll v7.4.2
  • Spire.Pdf.dll v5.4.2
  • Spire.XLS.dll v9.4.1
  • Spire.Email.dll v2.1.9
  • Spire.DocViewer.Forms.dll v4.3.1
  • Spire.PdfViewer.Forms.dll v4.4.1
  • Spire.PdfViewer.Asp.dll v4.4.1
  • Spire.Presentation.dll v4.3.20
  • Spire.Spreadsheet v3.3.2
  • Spire.OfficeViewer.Forms.dll v4.4.0
  • Spire.Barcode.dll v3.3.1
  • Spire.DataExport.dll v4.1.9
  • Spire.DataExport.ResourceMgr.dll v2.1.0
  • Spire.Common.dll v2.4.1
  • Spire.License.dll v1.3.7
Click the link to get the version Spire.Office 4.4.0:
More information of Spire.Office new release or hotfix:

Spire.PDF

New Features:

  • Supports finding and highlighting text that cross lines.
  • PdfDocument doc = new PdfDocument(input);
    PdfTextFind[] result = null;
    foreach (PdfPageBase page in doc.Pages)
    {
        result = page.FindText("This is a test", TextFindParameter.CrossLine).Finds;
        for (int i = 0; i < result.Length; i++)
        {
            result[i].ApplyHighLight(Color.Yellow);
        }
    }
    doc.SaveToFile(output); 
    
  • Supports adding digital signatures with LTV (Long Term Validation).
  • PdfNewDocument doc = new PdfNewDocument();
    PdfPageBase page = doc.Pages.Add();
    String pfxPath = inputFile;
    PdfCertificate cer = new PdfCertificate(pfxPath, password, X509KeyStorageFlags.Exportable);
    PdfSignature signature = new PdfSignature(doc, page, cer, "s1");
    signature.Bounds = new RectangleF(new PointF(100, 100), new SizeF(200, 200));
    signature.ConfigureHttpOCSP(null, null);
    doc.Save(outputFile);
    
  • Supports getting and setting the background color of the form field.
  • PdfRGBColor color = xxField.BackColor;
    xxField.BackColor = Color.Yellow;
    
  • Supports setting the coordinate position of the picture in PdfGridCell.
  • PdfGridCellContent cellContent = new PdfGridCellContent();
    cellContent.ImageLocation = new PointF(20,20);
    
  • Optimizes the printing speed.

Bug Fixes:

  • Fixes the issue that the number containing the decimal point was separated by two lines.
  • Fixes the issue the obtained image location was incorrect.
  • Fixes the issue document size became very large after multiple digital signatures were added
  • Fixes the issue that setting the column width of the table didn't work.
  • Fixes the issue that it threw a Win32Exception when printing a PDF document
  • Fixes the issue that the images became blurred when printing a PDF document
  • Fixes the issue that content styles were changed when converting a PDF document to images.
  • Fixes the issue that there was an error "No FunctionType specified in function" was thrown when extracting images.
  • Fixes the issue that there was an error "Object reference not set to an instance of an object" was thrown when extracting text.
  • Fixes an issue that some characters were missing and extra characters were added when extracting text.
  • Fixes an issue that the merged document could not be opened with the Microsoft Edge browser.
  • Fixes an issue that the barcode in the document was not displayed correctly when printing a PDF.
  • Fixes an issue that the content was truncated and lost when drawing text using the PdfTextWidget function.
  • Fixes an issue that the position of new text was slightly shifted down when replacing text.
  • Fixes an issue that the added image tag was changed.
  • Fixes an issue that the application threw the error "the reference object was not set to an instance of the object" when converting TIFF to PDF.
  • Fixes an issue that vertical text was garbled when converting PDF to images.
  • Fixes an issue that the application threw the error"the reference object was not set to an instance of the object" when merging PDFs containing hidden content.
  • Fixes an issue that the content was garbled when splitting a PDF document.
  • Fixed an issue that the application hung when finding text from a PDF.
  • Fixes an issue that some content was incorrect when merging PDF documents.
  • Fixes an issue that setting the checkbox field value did not take effect.
  • Fixes an issue that the space between numbers was increased when converting PDF to XPS.
  • Fixes an issue that the content was garbled when printing PDFs.
  • Fixes an issue that the application threw the error"index cannot be less than zero or greater than count" when merging documents.
  • Fixes an issue that PDF documents after rotating pages were opened incorrectly with the Microsoft Edge browser.

Spire.Presentation

New Features:

  • Supports adding text animation to specified paragraphs in shape.
  • Presentation ppt = new Presentation();
    ppt.LoadFromFile("test.pptx");
    IAutoShape shape = (IAutoShape)ppt.Slides[0].Shapes[0];
    AnimationEffect animation = shape.Slide.Timeline.MainSequence.AddEffect(shape, AnimationEffectType.Fly);
    animation.SetStartEndParagraphs(2, 3);
    IAutoShape shape2 = (IAutoShape)ppt.Slides[0].Shapes[1];
    AnimationEffect animation2 = shape.Slide.Timeline.MainSequence.AddEffect(shape2, AnimationEffectType.FadedZoom);
    animation2.SetStartEndParagraphs(0, 0);
    ppt.SaveToFile("result.pptx", FileFormat.Pptx2010);
    ppt.Dispose();
    
  • Improves print interface.
  • Presentation ppt = new Presentation();
    ppt.LoadFromFile(inputfile);
    PresentationPrintDocument document = new PresentationPrintDocument(ppt);
    //Set print task name
    document.DocumentName = "print task 1";
    document.Print0rder = Order.Horizontal;
    document.SlideFrameForPrint = true;
    document.GrayLevelForPrint = true;
    document.SlideCountPerPageForPrint = PageSlideCount.Three;
    document.PrinterSettings.PrintRange = PrintRange.AllPages;
    //Set continuous print area
    document.PrinterSettings.PrintRange = PrintRange.SomePages;
    document.PrinterSettings.FromPage = 1;
    document.PrinterSettings.ToPage = ppt.Slides.Count - 1;
    //Set discontinuous print area
    //document.SelectSldiesForPrint("1", "2-6");
    document.PrinterSettings.PrintToFile = true;
    document.PrinterSettings.PrintFileName = outputfile;
    ppt.Print(document);
    ppt.Dispose();
    

Bug Fixes:

  • Fixes the issue that the content format was incorrect when converting PPTX to PDF/PPT.
  • Fixed the issue that the chart was lost when converting PPT to PDF.
  • Fixed the issue that the process threw an InvalidCastException when loading a PPT document.
  • Fixed the issue that where the data was not updated correctly after modifying data source of chart
  • Fixes an issue that it threw the error "the object reference was not set to the object instance" when copying shape.
  • Fixes an issue that the chart was lost when converting PPT to images.
  • Fixes an issue that the datalabel was incorrect when converting PPT to PDF.
  • Fixes an issue that the the formula from chart datasource was not displayed when saving as a PPT file.
  • Fixes an issue that the legend still existed when converting to PDF after deleting chart legend.
  • Fixes an issue that the images content were incorrect when converting PPT to PDF.
  • Fixes the issue that the result was incorrect when converting PPT to images.
  • Fixes the issue that the application threw an exception when setting the value of ChartData.
  • Fixes the issue that the application threw and exception when saving PPT to images.
  • Fixes the issue that a datalable of a chart was missing when converting PPT to PDF.
  • Fixes the issue that the format of the data changed after saving PPT to images.
  • Fixes the issue that the chart data updated incorrectly after changing the chart data.
  • Fixes the issue that the position of the content changed after converting PPT to PDF.
  • Fixes the issue that the image moved from left to right when converting PPT to PDF.

Spire.Doc

New Features:

  • Supports to get or set the value that determines whether the space is automatically adjusted between Asian text and numbers.
  • Paragraph.Format.AutoSpaceDN;
    
  • Supports to get or set the value that determines whether the space is automatically adjusted between Asian and Latin text.
  • Paragraph.Format.AutoSpaceDE;
    

Bug Fixes:

  • Fixes the issue that the application threw an exception when saving the Word document to PDF.
  • Fixes the issue that the page break was incorrect after saving Word to image.
  • Fixes the issue that setting read only for part content didn't work when saving to .doc format file.
  • Fixes the issue that the bold effect was lost when converting Word to PDF.
  • Fixes the issue that the application threw an exception when loading a Word file.
  • Fixes the issue that the application threw the StackOverflowException when saving the Word document to PDF.
  • Fixes the issue that the field didn't update correctly after merging files.
  • Fixes the issue that the cells were split incorrectly when saving to .doc format file.
  • Fixes the issue that the hidden image displayed after converting Word to PDF.
  • Fixes the issue that the format was wrong after merging files.
  • Fixes the issue that there was extra footer after updating TOC.

Spire.XLS

New Features:

  • Supports to set the location of the content in textbox.
  • TextBoxShapeBase texbox = workbook.Worksheets[0].TextBoxes[0] as TextBoxShapeBase;
    texbox.InnerLeftMargin = 1;
    texbox.InnerRightMargin = 3;
    texbox.InnerTopMargin = 1;
    texbox.InnerBottomMargin = 3; 
    

Bug Fixes:

  • Fixes an issue that the rotation of the shape didn't work when saving to ExcelVersion.Version97to2003.
  • Fixes an issue that an error dialog popped up when opening a document after copying the formulas and saving it to an .xlsx file.
  • Fixes an issue that image transparency was lost after saving as an .xls document.
  • Fixes an issue that caused incorrect content after converting Excel to PDF.
  • Fixes an issue that setting DocumentProperties of version97-2003 format but didn't take effect.
  • Fixes an issue that caused exception (“XmlException was unhandled”) when loading Excel.
  • Fixes an issue that the DisplayedText of Excel cell could not be obtained correctly.
  • Fixes an issue that after saving as a new Excel file, an error dialog popped up when opening the saved Excel.
  • Fixes an issue that the count of NameRange could not be obtained correctly.

Spire.Spreadsheet

New Features:

  • Supports customizing language configuration file path.
  • spreadsheet.MenuLanguageConfigPath= "D:/SpreadsheetTest/MenuLanguageConfig.xml";
    
  • Supports recovery shortcut(Ctril + Y).
  • Reduces the width of the rounding border when the cell is selected.

Bug Fixes:

  • Fixes an issue that it threw an ArgumentException when loading an xls document.
  • Fixes an issue that the minus sign was lost when the negative value was displayed in the SpreadSheet.
  • Fixes an issue that the right side of the border would move to the right when dragging the scroll bar to the left.