回復 7#freeffly
sheets.add.name="0322資料" 語法錯誤
用 WITH 是便於處裡 WITH 物件的屬性, 方法.
Sub Ex()
With Sheets.Add
.Name = "0322資料"
.Range("A1:C1") = Array(1, 2, 3)
.Range("A1:C1").Select
End With
End Sub
同上
Sub Ex()
Sheets.Add
ActiveSheet.Name = "0322資料"
ActiveSheet.Range("A1:C1") = Array(1, 2, 3)
ActiveSheet.Range("A1:C1").Select
End Sub作者: freeffly 時間: 2011-3-22 20:23