Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The LMX_ClientStoreLoad function loads content saved in the client store.

Prototype

Code Block
languagecpp
LMX_STATUS LMX_ClientStoreLoad
(
   LMX_HANDLE LmxHandle,
   const char *szVirtualFilename,
   char *szString
);

Parameters

LmxHandle
[in/out] LM-X handle.

...

szString
[out] The content to load from the client store.

Return values

On success, this function returns the status code LMX_SUCCESS.

On failure, this function returns an error code in the format described in Return codes.

Remarks

The LMX_ClientStoreLoad function and the  LMX_ClientStoreSave function work together to store sensitive license information in an encrypted manner into the client store.

...

See Secure store and Client store for more information about secure store and client store.

Example

The following is a basic example of using LMX_ClientStoreLoad, which loads the content saved in "myFile" and displays it as "m" string.

Code Block
languagecpp
#include <lmx.h>
#include <stdio.h>

LMX_HANDLE h;

int main() 
{
  char m[LMX_MAX_LONG_STRING_LENGTH];

  exit_on_error(LMX_Init(&h));
  exit_on_error(LMX_ClientStoreSave(h, "myFile", "DataToBeStored"));

  exit_on_error(LMX_ClientStoreLoad(h, "myFile", m));
  printf("Loaded: %s\n", m);

  return 0;
}