Hola juank1971.
Si ya le diste un nombre a cada mesa, podés buscarlas por su nombre con el método
FindComponent.
Por ejemplo:
Código Delphi
[-]
var
C: TComponent;
begin
C:= FindComponent('M'+IntToStr(ID_Mesa)); if Assigned(C) then
begin
TGroupBox(C).Color:= clRed;
...
Saludos.