System.AnsiStringT.LoadStr
C++
static AnsiStringT LoadStr(int ident) {
static AnsiStringT LoadStr(HINSTANCE hInstance, int ident) {
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
function | public | dstring.h | System | AnsiStringT |
Description
Loads a string from the compiled resources of a specified module.
LoadStr loads a specified string resource.
ident is the resource identifier of the string.
hInstance is the instance handle of the module that contains the string resource. If hInstance is not given, LoadStr loads the string from the current module (executable or shared library).
If the string resource does not exist, LoadStr returns an empty string.
Moving display strings into string resources makes an application easier to localize without rewriting the program.