Label1.Caption := FormatDateTime('yyyy', IncMonth(now, -12));
Label1.Caption := Copy(DateTimeToStr(IncMonth(Now, -12)), 1, 4);

解决方案 »

  1.   

    请参考:
    var y,m,d:word;decodedate(date(),y,m,d);
    y:=y-1;
    showmessage(inttostr(y));
      

  2.   

    var
        a:tcalendar;
    begin
        label1.caption:=inttostr(a.year);
    end;
      

  3.   

    今年是2002,now中的年份当然是2002而非2001Label1.Caption:=FormatDateTime('yyyy',now);
    Label1.Caption := IntToStr(StrToInt(copy(DateTimeToStr(Now),1,4))-1);
      

  4.   

    Label1.Caption:=FormatDateTime('yyyy',now-365);
      

  5.   

    Up!Up!Up!Up!Up!-------------------------
    你给我分我捧你!
    不给我分我扁你!
      

  6.   

    decodedate(date(),y,m,d);
    encodedate(y,1,1)-1