Hola DavidSG4.
Como cada mes del año tiene cuatro semanas se me ocurre que podría hacerse de este modo:
Código Delphi
[-]
uses DateUtils;
function Semana(Date: TDate): Integer;
var
dd: Integer;
begin
dd:= DayOf(Date);
Result := (MonthOf(Date)-1) * 4; if (dd > 0)and(dd < 8) then
Inc(Result, 1)
else if (dd > 7)and(dd < 15) then
Inc(Result, 2)
else if (dd > 14)and(dd < 22) then
Inc(Result, 3)
else
Inc(Result, 4);
end;
Ejemplo de llamada:
Código Delphi
[-]
ShowMessage(Format('Semana: %d',[Semana(Now)]));
Saludos.