發表文章

目前顯示的是 11月, 2021的文章

田庭聿EXCEL基本功能,VBA巨集程式設計

圖片
  畫圖VBA程式碼 'Dr Ian O'Connor, CPA. - located in Victoria, Australia. '2021/11/29劉任昌指導我從 Option Explicit Const topleft As String = "C5" ' anchor cell Const diam As Integer = 180 ' points Dim Shp As Shape '宣告dim 變數Shp是圖形Shape global Sub xlfAddCircle1() Dim TLCleft As Double 'local variables區域變數 Dim TLCtop As Double TLCleft = Range(topleft).Left TLCtop = Range(topleft).Top Set Shp = ActiveSheet.Shapes.AddShape(Type:=msoShapeOval, _ Left:=TLCleft, Top:=TLCtop, _ Width:=diam, Height:=diam) With Shp .Fill.Visible = msoFalse .Line.Weight = 10 .Line.ForeColor.Brightness = 0.4 .ThreeD.BevelTopType = msoBevelCircle End With End Sub Sub 劉任昌超級臭屁() Dim x As Double '宣告 x 是倍精度double Dim y As Double '宣告 y 是倍精度double Dim i As Integer '選告整數i For i =...