Class DisplayValue
Inherited Members
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. |