alexa
menu

Blazor

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Search Results for

    Show / Hide Table of Contents

    Class CellSavedEventArgs

    Provides data for the CellSaved event.

    Inheritance
    object
    CellSavedEventArgs
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Syncfusion.Blazor.Spreadsheet
    Assembly: Syncfusion.Blazor.Spreadsheet.dll
    Syntax
    public class CellSavedEventArgs
    Remarks

    This class contains details about the saved cell, including its address, old and new values, display text, and the action that triggered the save.

    The event is triggered after a cell's value has been successfully saved, allowing for post-save operations or logging.

    Use this event to track changes, update related data, or perform validation after the save operation.

    Examples

    This example demonstrates how to handle the CellSaved event to log cell changes.

    <SfSpreadsheet CellSaved="OnCellSaved">
    </SfSpreadsheet>
    
    @code {
        private void OnCellSaved(CellSavedEventArgs args)
        {
            // Log the cell change, including the action that triggered it.
            Console.WriteLine($"Cell {args.Address} changed from '{args.OldValue}' to '{args.Value}' by {args.Action}.");
        }
    }

    Constructors

    CellSavedEventArgs()

    Declaration
    public CellSavedEventArgs()

    Properties

    Action

    Gets the action that triggered the cell save event.

    Declaration
    public string Action { get; }
    Property Value
    Type Description
    string

    A string indicating the type of action that triggered the save operation, such as "Edit", "Cut", "Paste", "Autofill", etc. The default value is null.

    Remarks

    This property helps distinguish between different types of save operations.

    It can be used to apply different logic based on how the cell was modified.

    Address

    Gets the address of the cell that was saved.

    Declaration
    public string Address { get; }
    Property Value
    Type Description
    string

    A string representing the cell address in the format "SheetName!A1". The default value is null.

    Remarks

    This property provides the full qualified address including the sheet name and cell reference.

    It can be used to identify the exact location of the saved cell within the spreadsheet.

    DisplayText

    Gets the display text of the new value.

    Declaration
    public string DisplayText { get; }
    Property Value
    Type Description
    string

    A string representing the formatted display text of the cell value. The default value is null.

    Remarks

    This property provides the visible text in the cell after formatting.

    It is useful for scenarios where the raw value differs from the displayed content, such as with dates or numbers.

    OldValue

    Gets the original value of the cell before it was changed.

    Declaration
    public object OldValue { get; }
    Property Value
    Type Description
    object

    A object representing the previous cell value. The default value is null.

    Remarks

    This property allows comparison between old and new values for change tracking.

    It is useful for implementing undo functionality or auditing changes.

    Value

    Gets the new value of the cell.

    Declaration
    public object Value { get; }
    Property Value
    Type Description
    object

    A object representing the updated cell value. The default value is null.

    Remarks

    This property holds the value that was just saved to the cell.

    It may differ from DisplayText if formatting is applied.

    In this article
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved