Click to See Complete Forum and Search --> : Win32 taskbar


arold85
July 28th, 2009, 09:09 AM
I want currently write a small program to change taskbar positon to put it
on the left corner.
But I'm don't know how can I make it.I proceed as follow:

// Get the handle of taskbar

HWND hTray = FindWindow(_T("Shell_TrayWnd"), NULL);
RECT rc = GetWindowRect(hTray,&rc);

APPBARDATA abd;
abd.cbSize = sizeof(APPBARDATA);

abd.hWnd = hTray;
abd.uEdge = ABE_LEFT;
abd.rc.bottom = GetSystemMetrics(SM_CYSCREEN);
abd.rc.left = GetSystemMetrics(SM_CXSCREEN);
SHAppBarMessage(ABM_WINDOWPOSCHANGED, &abd);