src/Helpers.c
UINT GetDlgItemTextW2MB(HWND hDlg, int nIDDlgItem, LPSTR lpString, int nMaxCount)
{
  WCHAR wsz[FNDRPL_BUFFER] = { L'\0' };
  UINT uRet = GetDlgItemTextW(hDlg, nIDDlgItem, wsz, COUNTOF(wsz));
  ZeroMemory(lpString,nMaxCount);
  WideCharToMultiByte(Encoding_SciCP, 0, wsz, -1, lpString, nMaxCount - 1, NULL, NULL);
  return uRet;
}
//=============================================================================
//
//  A2W: Convert Dialog Item Text form Unicode to UTF-8 and vice versa
//
Convert Dialog Item Text form Unicode to UTF-8 and vice versa
Convert Dialog Item Text form Unicode to UTF - 8 and vice versa
UINT GetDlgItemTextW2MB(HWND hDlg, int nIDDlgItem, LPSTR lpString, int nMaxCount)
{
  WCHAR wsz[FNDRPL_BUFFER] = { L'\0' };
  UINT uRet = GetDlgItemTextW(hDlg, nIDDlgItem, wsz, COUNTOF(wsz));
  ZeroMemory(lpString,nMaxCount);
  WideCharToMultiByte(Encoding_SciCP, 0, wsz, -1, lpString, nMaxCount - 1, NULL, NULL);
  return uRet;
}
UINT GetDlgItemTextW2MB ( HWND hDlg , int nIDDlgItem , LPSTR lpString , int nMaxCount ) { WCHAR wsz [ FNDRPL_BUFFER ] = { L' \0 ' } ; UINT uRet = GetDlgItemTextW ( hDlg , nIDDlgItem , wsz , COUNTOF ( wsz ) ) ; ZeroMemory ( lpString , nMaxCount ) ; WideCharToMultiByte ( Encoding_SciCP , 0 , wsz , -1 , lpString , nMaxCount - 1 , NULL , NULL ) ; return uRet ; }
A2W: Convert Dialog Item Text form Unicode to UTF-8 and vice versa
A2W : Convert Dialog Item Text form Unicode to UTF - 8 and vice versa