Are you getting any error messages?

You may want to try the following as \\ in C is usually used for escaping sequences, so in Pascal you should only need 1 \

[pascal]
var
msndata: CopyDataStruct;
msnwindow: HWND;
utf16buffer: WideString;
begin
utf16buffer := '\0Music\00\0{0} - {1}\0\0\0\0\0';
msndata.dwData := $547;
msndata.cbData := ( Length(utf16buffer) * 2 ) + 2;
msndata.lpData := Pointer(utf16buffer);
msnwindow := 0;

repeat
msnwindow := FindWindowEx(0, msnwindow, 'MsnMsgrUIManager', nil);
SendMessage(msnwindow, WM_CLOSE, WM_CLOSE,Integer(@msndata));
until msnwindow = 0;
end;
[/pascal]