LocalizationHelperGetString(String, LocalizationContext, Object) Method
Gets a localized string for the specified
key using the specified
context and formatting arguments.
It invokes the
LocalizationRequested event to retrieve the string resource format. If the event is not handled,
and a resource set is available for the specified context, it retrieves the string from that resource set.
Namespace: KGySoft.WinFormsAssembly: KGySoft.WinForms (in KGySoft.WinForms.dll) Version: 5.0.1
public static string? GetString(
string key,
LocalizationContext? context,
params Object?[]? args
)
Public Shared Function GetString (
key As String,
context As LocalizationContext,
ParamArray args As Object()
) As String
public:
static String^ GetString(
String^ key,
LocalizationContext^ context,
... array<Object^>^ args
)
static member GetString :
key : string *
context : LocalizationContext *
args : Object[] -> string
- key String
- The key of the requested string resource. When args has values, the key is expected to be a format string.
- context LocalizationContext
- The localization context to use for the operation. If , no context is used.
- args Object
- The formatting arguments to be applied to the localized string format.
StringThe localized and formatted string for the specified
key if found; otherwise,
.