- Search string now assumed with * at the ends in object browser
[public/netxms.git] / src / console / win32 / ObjectSearchBox.cpp
index 1c1d54f..8dee766 100644 (file)
@@ -112,9 +112,11 @@ HBRUSH CObjectSearchBox::OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor)
 
 void CObjectSearchBox::OnFindObject()
 {
-   char szBuffer[256];
+   TCHAR szBuffer[256];
 
-   m_wndEditBox.GetWindowText(szBuffer, 255);
+   szBuffer[0] = _T('*');
+   m_wndEditBox.GetWindowText(&szBuffer[1], 255);
+   _tcscat(szBuffer, _T("*"));
    GetParent()->SendMessage(WM_FIND_OBJECT, 0, (LPARAM)szBuffer);
 }