Dim dflrow As Integer
ActiveWorkbook.Sheets("ElecTM").Range("I1048576").Select
dflrow = Selection.End(xlUp).Row
' ActiveWorkbook.Sheets("ElecTM").Range("AG" & dflrow & ":" & "AJ" & dflrow).Select
ActiveWorkbook.Sheets("ElecTM").Range("AG6").Formula = "=CONCATENATE(Year(I6),"w",WeekNum(I6))"
Selection.FillDown
在这里,我收到一条错误消息,指出第五行的语法错误。我试过'.value'而不是'.Formula'。但这没有帮助。