menu

WPF

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class SearchManager - WPF API Reference | Syncfusion

    Show / Hide Table of Contents

    Class SearchManager

    Class which provides support to find or replace the text in the document with advanced search options. And also provides support to select all cells with formulas, conditional formatting, constants, data validation, etc.

    Inheritance
    System.Object
    SearchManager
    Implements
    System.IDisposable
    Inherited Members
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: Syncfusion.UI.Xaml.Spreadsheet
    Assembly: Syncfusion.SfSpreadsheet.WPF.dll
    Syntax
    public class SearchManager : IDisposable

    Constructors

    SearchManager(SfSpreadsheet)

    Hold the spreadsheet instance.

    Declaration
    public SearchManager(SfSpreadsheet spreadsheet)
    Parameters
    Type Name Description
    SfSpreadsheet spreadsheet

    Methods

    Dispose()

    Dispose maintained instances.

    Declaration
    public void Dispose()

    Dispose(Boolean)

    Declaration
    protected virtual void Dispose(bool disposing)
    Parameters
    Type Name Description
    System.Boolean disposing

    FindAll(IWorkbook, String, SearchBy, ExcelFindType, Boolean, Boolean)

    Returns all matched ranges within the workbook based on the given options.

    Need to specify the workbook to perform find all operation. Need to specify the search text to perform find all operation. Searchby option is used to determine the find all operation performed in row wise or column wise. Find type option is used to determine the find all operation perform whether on formulas or values. Match case option is used to determine the find all operation perform whether on case sensitive text or not. Match entire cell contents option is used to determine the find all operation perform on in which cell content is matched with given find text. Returns found ranges in array format
    Declaration
    public IRange[] FindAll(IWorkbook workbook, string searchText, SearchBy searchByOption, ExcelFindType findType, bool matchCase, bool matchEntireCell)
    Parameters
    Type Name Description
    IWorkbook workbook
    System.String searchText
    SearchBy searchByOption
    ExcelFindType findType
    System.Boolean matchCase
    System.Boolean matchEntireCell
    Returns
    Type
    IRange[]

    FindAll(IWorksheet, String, SearchBy, ExcelFindType, Boolean, Boolean)

    Returns all matched ranges within the specified worksheet based on the given options.

    Need to specify the worksheet to perform find all operation. Need to specify the search text to perform find all operation. Searchby option is used to determine the find all operation performed in row wise or column wise. Find type option is used to determine the find all operation perform whether on formulas or values. Match case option is used to determine the find all operation perform whether on case sensitive text or not. Match entire cell contents option is used to determine the find all operation perform on in which cell content is matched with given find text. Returns found ranges in array format
    Declaration
    public IRange[] FindAll(IWorksheet worksheet, string searchText, SearchBy searchByOption, ExcelFindType findType, bool matchCase, bool matchEntireCell)
    Parameters
    Type Name Description
    IWorksheet worksheet
    System.String searchText
    SearchBy searchByOption
    ExcelFindType findType
    System.Boolean matchCase
    System.Boolean matchEntireCell
    Returns
    Type
    IRange[]

    FindConditionalFormatting(IWorksheet)

    Returns ranges which have conditional formatting within the specified worksheet..

    Declaration
    public IRange[] FindConditionalFormatting(IWorksheet worksheet)
    Parameters
    Type Name Description
    IWorksheet worksheet

    Need to specify the worksheet to find the conditional format applied ranges.

    Returns
    Type Description
    IRange[]

    Returns array ranges.

    FindConstants(IWorksheet)

    Returns ranges which have constants within the specified worksheet..

    Declaration
    public IRange[] FindConstants(IWorksheet worksheet)
    Parameters
    Type Name Description
    IWorksheet worksheet

    Need to specify the worksheet to find the constants.

    Returns
    Type Description
    IRange[]

    Returns array ranges

    FindDataValidation(IWorksheet)

    Returns ranges which have data validation within the specified worksheet..

    Declaration
    public IRange[] FindDataValidation(IWorksheet worksheet)
    Parameters
    Type Name Description
    IWorksheet worksheet

    Need to specify the worksheet to find the datavalidation applied range.

    Returns
    Type Description
    IRange[]

    Returns array ranges

    FindFormulas(IWorksheet)

    Returns ranges which have formulas within the specified worksheet..

    Declaration
    public IRange[] FindFormulas(IWorksheet worksheet)
    Parameters
    Type Name Description
    IWorksheet worksheet

    Need to specify the worksheet to find the formulas.

    Returns
    Type Description
    IRange[]

    Returns array ranges

    FindNext(IWorkbook, String, SearchBy, ExcelFindType, Boolean, Boolean)

    Returns immediate matched range from the current range within the workbook based on the given options.

    Need to specify the workbook to perform find next operation. Need to specify the search text to perform find next operation. Searchby option is used to determine the find next operation performed in row wise or column wise. Find type option is used to determine the find next operation perform whether on formulas or values. Match case option is used to determine the find next operation perform whether on case sensitive text or not. Match entire cell contents option is used to determine the find next operation perform on in which cell content is matched with given find text. Returns found range.
    Declaration
    public IRange FindNext(IWorkbook workbook, string searchText, SearchBy searchByOption, ExcelFindType findType, bool matchCase, bool matchEntireCell)
    Parameters
    Type Name Description
    IWorkbook workbook
    System.String searchText
    SearchBy searchByOption
    ExcelFindType findType
    System.Boolean matchCase
    System.Boolean matchEntireCell
    Returns
    Type
    IRange

    FindNext(IWorksheet, String, SearchBy, ExcelFindType, Boolean, Boolean)

    Returns immediate matched range from the current range within the specified worksheet based on the given options.

    Need to specify the worksheet to perform find next operation. Need to specify the search text to perform find next operation. Searchby option is used to determine the find next operation performed in row wise or column wise. Find type option is used to determine the find next operation perform whether on formulas or values. Match case option is used to determine the find next operation perform whether on case sensitive text or not. Match entire cell contents option is used to determine the find next operation perform on in which cell content is matched with given find text. Returns found range.
    Declaration
    public IRange FindNext(IWorksheet worksheet, string searchText, SearchBy searchByOption, ExcelFindType findType, bool matchCase, bool matchEntireCell)
    Parameters
    Type Name Description
    IWorksheet worksheet
    System.String searchText
    SearchBy searchByOption
    ExcelFindType findType
    System.Boolean matchCase
    System.Boolean matchEntireCell
    Returns
    Type
    IRange

    ReplaceAll(IWorkbook, String, String, Boolean, Boolean)

    Returns replaced ranges within the workbook based on the given options.

    Need to specify the workbook to perform replace all operation. Need to specify the search text to perform replace all operation. Need to specify the replace text to perform replace all operation. Match case option is used to determine the replace all operation perform whether on case sensitive text or not. Match entire cell contents option is used to determine the replace all operation perform on in which cell content is matched with given find text. Returns all replaced ranges.
    Declaration
    public IRange[] ReplaceAll(IWorkbook workbook, string searchText, string replaceText, bool matchCase, bool matchEntireCell)
    Parameters
    Type Name Description
    IWorkbook workbook
    System.String searchText
    System.String replaceText
    System.Boolean matchCase
    System.Boolean matchEntireCell
    Returns
    Type
    IRange[]

    ReplaceAll(IWorksheet, String, String, Boolean, Boolean)

    Returns replaced ranges within the specified worksheet based on the given options.

    Need to specify the worksheet to perform replace all operation. Need to specify the search text to perform replace all operation. Need to specify the replace text to perform replace all operation. Match case option is used to determine the replace all operation perform whether on case sensitive text or not. Match entire cell contents option is used to determine the replace all operation perform on in which cell content is matched with given find text. Returns replaced ranges.
    Declaration
    public IRange[] ReplaceAll(IWorksheet worksheet, string searchText, string replaceText, bool matchCase, bool matchEntireCell)
    Parameters
    Type Name Description
    IWorksheet worksheet
    System.String searchText
    System.String replaceText
    System.Boolean matchCase
    System.Boolean matchEntireCell
    Returns
    Type
    IRange[]

    Implements

    System.IDisposable
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved