logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Class DisplayValue

    Inheritance
    object
    DisplayValue
    Inherited Members
    object.ToString()
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    Namespace: Serenity.Shared.Utils
    Assembly: Serenity.Shared.dll
    Syntax
    public static class DisplayValue

    Methods

    GetDisplayValue(string, string)

    Gets a "friendly" value to display in UI.
    If Value is null, empty, or looks like a GUID, return Key.

    Declaration
    public static string GetDisplayValue(string key, string value)
    Parameters
    Type Name Description
    string key
    string value
    Returns
    Type Description
    string

    The display value based on the provided key and value.

    GetDisplayValue((string key, string value))

    Gets a "friendly" value to display in UI.
    If Value is null, empty, or looks like a GUID, return Key.

    Declaration
    public static string GetDisplayValue((string key, string value) keyValue)
    Parameters
    Type Name Description
    (string key, string value) keyValue

    The key-value pair to evaluate.

    Returns
    Type Description
    string

    The display value based on the provided key and value.

    In this article
    © 2026 Serenity. All Rights Reserved