發表文章

目前顯示的是 6月, 2011的文章

Excel Transpose 改變動態二維陣列的「列」邊界

技巧124      p.188 Sub AddArrayBorder()     Dim i As Integer     Dim j As Integer     Dim arr     ReDim arr(1 To 2, 1 To 3)     For i = 1 To 2         For j = 1 To 3             arr(i, j) = i * j         Next j     Next i     arr = Application.WorksheetFunction.Transpose(arr)     ReDim Preserve arr(1 To 3, 1 To 5)     arr = Application.WorksheetFunction.Transpose(arr)     For i = 3 To 5         For j = 1 To 3             arr(i, j) = i * j         Next j     Next i     Sheet1.Range("A1").Resize(5, 3) = arr End Sub

Excel Msgbox vbYesNo 使用方法

If MsgBox("是否要覆寫", vbYesNo, "title") = vbNo Then     msgbox "選擇的是no " else     msgbox "選擇的是yes " end if

Excel Transpose 儲存格值、轉置資料

'陣列轉置      dim Arr2,arr_tmp      dim ShtNo as object      dim LenArr2 as Integer      Set ShtNo = Sheets("數字表")      Arr2 = Application.WorksheetFunction.Transpose(arr_tmp)      LenArr2 = UBound(Arr2, 1)      ShtNo.Cells(4, 7).Resize(LenArr2, 1) = Arr2

Excel Sort,不含標題排序

        With ShtBaseImg             lLastRow = .Range("A" & Cells.Rows.Count).End(xlUp).Row             Set BaseImg_Rng = .Cells(6, 1).CurrentRegion             BaseImg_Rng.Cells(1, 1).Sort _                 key1:=.Columns(1).Cells, Order1:=xlAscending, Header:=xlGuess         End With         加上 Header:=xlGuess,就可以不含標題排序

Excel 迴圈的掛法

例如 var = 10 for x =  1 to 10     call function x1 (var) next x function x1 (var)         for y = 1 to var         debug.print 1 function 如果,變數是從外層代入 那麼,掛在外層,日後會比較好維護 如下 var = 10 for x =1 to 10     for y = 1 to var        call function x1 (var)     next y next x function x1 (var)                debug.print 1 function

android 系統安裝嘸蝦米

1、下載字根表boshimay(42880).lime                 http://www.megaupload.com/?d=VJCES7WR 2、手機內建LIME資料夾                 複製進  LIME\boshimay(42880).lime 3、使用手機的 market 程式,搜找LIME-HD                 安裝LIME-HD 4、設定LIME-HD,                [初始資料庫]                        如果 (字根放進內存記憶體)選                             →預載資料庫                        如果 (字根放進記憶卡)選                           ...