1. Package component
   Middleware setup package contains two files NGSetup.DLL and NGSetup.DAT.
   NGSetup.DLL is the setup library
   NGSetup.DAT is the resource file

2. API definition
   DWORD WINAPI instMW_Install(const char* szParam)
         To support smartcard/VPN logon, set parameter ("regatr=true")
         For multiple settings, separate them by using ";" e.g. ("path=NGSetup.DAT;regatr=true")
         If do not need to support smartcard/VPN logon, call this API directly

   DWORD WINAPI instMW_Uninstall(const char* szParam)
         Null or the path of DAT file can be set as parameter

   DWORD WINAPI instMW_IsHaveInstalled(const char* szParam)
         Null or the path of DAT file can be set as parameter

   DWORD WINAPI instMW_IsNeedReboot(void)

3. Return value definition
   instMW_Install and instMW_Uninstall
      #define ESA_SUCCESS               0x0000 //Success
      #define ESA_ERR_FILE_NOT_FOUND    0x0001 //File is not found
      #define ESA_ERR_COPY_FILES        0x0002 //Copy file failed
      #define ESA_ERR_REG               0x0003 //Register file failed
      #define ESA_ERR_REG_CSP           0x0004 //Register CSP failed
      #define ESA_ERR_UNREG             0x0005 //Unregister CSP failed
      #define ESA_ERR_DEL_FILES         0x0006 //Delete file failed
      #define ESA_ERR_DEL_DIR           0x0007 //Delete folder failed
      #define ESA_ERR_EXCTOR_FILES      0x0008 //Extract file to temp folder failed
      #define ESA_ERR_HOST_MEMORY       0x0009 //Memory error
      #define ESA_ERR_REG_CARD_REG      0x000A //Register smartcard driver failed
      #define ESA_ERR_PRODUCT_ALD_INST  0x000B //Middleware is installed already
      #define ESA_ERR_NEEDREBOOT        0x000C //Need reboot

   instMW_IsHaveInstalled
      #define ESA_NEVER_INSTALL         0 //Middleware is not installed
      #define ESA_DEST_DVERSION_OLD     1 //Middleware is installed. Installed version is old
      #define ESA_DEST_DVERSION_EQUAL   2 //Middleware is installed. Installed version is same
      #define ESA_DEST_DVERSION_NEW     3 //Middleware is installed. Installed version is new

   instMW_IsNeedReboot
      0  //Reboot is not needed
      1  //Need to reboot

Note:
   NGSetup.dat, NGSetup.dll and NGSetup.lib files in Lib\setup folder are needed
   msvcp60.dll is needed in system32 folder
   User needs to logon as administrator to perform installation/uninstallation