發表文章

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

EXCEL VBA雙迴圈JavaScript雙迴圈

圖片
VBA迴圈畫圖 VBA迴圈畫圖程式碼 'https://excelatfinance.com/xlf19/xlf-qg-add-blue-circle.php Option Explicit Const topleft As String = "C5" ' anchor cell Const diam As Integer = 100 ' 宣告常數constant diam 100 Dim Shp As Shape 'global variables全域變數 ' =========================== Sub 劉任昌() Dim TLCleft As Double Dim TLCtop As Double Dim i As Integer '宣告整數integer i For i = 1 To 20 'write a loop單引號註解 TLCleft = 20 * i '距離左邊left TLCtop = 20 * i '距離上面top '使用中的試算表active sheet. addshape(type, left, top, width, height) Set Shp = ActiveSheet.Shapes.AddShape(msoShapeOval, TLCleft, TLCtop, 2 * diam, diam) With Shp .Fill.Visible = msoFalse .Line.Weight = 10 .Line.ForeColor.Brightness = 0.4 .ThreeD.BevelTopType = msoBevelCircle End With Next With Cells(1, 1) .Value = "劉任昌大帥哥" '在儲存格1,1放入字串 .Interior.Color = RGB(0, 0, 255) .Columns...

劉任昌清單方塊ListBox與核取方塊CheckBox

圖片
期中考後追加補充 非巢狀 if (r) present("#FF0000"); if (g) present("#00FF00");//沒有滿足(r)就執行 if (b) present("#0000FF"); 巢狀 if (r) present("#FF0000"); else if (g) present("#00FF00");//沒有滿足(r)就執行 else if (b) present("#0000FF"); else alert("豬頭你沒有選擇顏色"); 期中考 喜愛 沒意見 討厭 紅色 綠色 藍色 粗體 輸出 期中考 巢狀IF條件 在style 區塊定義CSS EXCEL