I think that about an hour is quite enough time to stuff around with a simple problem, so I thought I'd quit before I got too frustrated and post on here.

I'm trying to make a small program to search my mp3 collection for a song and then allow me to either immediately play or enqueue the results in winamp.

The problem here is that the name and size of the files are added on different lines. In fact, the sizes of all but one file are added first (in the size column) and then the names of the files are added underneath (in the name column). And finally the last file size is added to the end of them (in the size column).

Maybe I'm completely misinterpreting the FindFirst/Next functions, but this should work properly shouldn't it?

Code:
procedure TForm1.SearchButClick(Sender: TObject);
var sr: TSearchRec;
begin
  with Output.Items do begin
    Clear;
    if FindFirst('E:\Music\*' + SearchBox.Text + '*.mp3', faAnyFile, sr) = 0 then begin
      repeat
        Add.Caption := sr.Name;
        Add.SubItems.Add(IntToStr(sr.Size));
      until FindNext&#40;sr&#41; <> 0;
      FindClose&#40;sr&#41;;
    end;
  end;
Oh, and also how can I make it alternate alphabetical sorting by clicking on the name column? You know, click once and it's A-Z, click again and it's Z-A...