這個網誌中的熱門文章
王襄榕EXCEL與JavaScript迴圈
輸出 EXCEL學習 '變數variables應該要宣告 pre=preserve保留 Option Explicit '要求所有變數必須宣告才能使用 Dim i, j As Integer 'Dimension 宣告指令 Public Sub 劉任昌() Cells(1, 1).Value = 12345 Cells(1, 1).Font.Color = RGB(0, 0, 256) Cells(1, 1).Font.Bold = True End Sub Public Sub 豬八戒() For i = 1 To 7 For j = 1 To 5 Cells(i, j).Value = i * j Next Next End Sub 畫圖畫面 畫圖程式碼 '拷貝自https://excelatfinance.com/xlf19/xlf-... '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, T...
王襄榕清單方塊ListBox與CheckBox核取方塊
巢狀條件if else 期中考非巢狀 三道指令,每一個指令都執行,例如已經滿足(r),另外二道還是去執行。 if (r) present("#FF0000"); if (g) present("#00FF00"); if (b) present("#0000FF"); 期中考巢狀 變成四道指令,提升程式效率 if (r) present("#FF0000"); else if (g) present("#00FF00");//沒有滿足(r)就執行 else if (b) present("#0000FF"); else alert("輸入的顏色條件,不滿足r,g,b,其他的!"); 11月第一週期中考 喜愛 沒意見 討厭 紅色 綠色 藍色 粗體 輸出 王襄榕期中報告心得 ANSI:美國國家標準協會 Unicode:聯盟官方中文名稱為統一碼,臺灣官方中文名稱為萬國碼,也譯為國際碼、單一碼 ASCII(American Standard Code for Information Interchange):美國資訊交換標準代碼 rgb王襄榕清單方塊ListBox與CheckBox核取方塊 自訂函數d11017135 rgb yellow
留言
張貼留言