小说网 找小说 无限小说 烟雨红尘 幻想小说 酷文学 深夜书屋

04 2006 档案

excel sheet中数据的快速复制
摘要:'利用Copymemory 复制数组,实现excel sheet中数据的任意复制,粘贴区域小于复制区域,数据将被截取,否则将用空格填充 Private Declare Sub CopyMemory Lib "kernel32" Alias "RtlMoveMemory" (pDst As Any,... 阅读全文

posted @ 2006-04-25 13:06 王峰炬 阅读(414) 评论(0) 推荐(0)

计算数组的维数
摘要:Option ExplicitPrivate Declare Sub CopyMemory Lib "kernel32" Alias "RtlMoveMemory" (Destination As Any, source As Any, ByVal Length As Long) Private ... 阅读全文

posted @ 2006-04-24 09:42 王峰炬 阅读(131) 评论(0) 推荐(0)

API判断数组是否为空
摘要:Private Declare Function SafeArrayGetDim Lib "oleaut32.dll" (ByRef saArray() As Any) As Long 'API判断数组为空或没有初始化 Sub diag()Dim msg As StringDim arr1... 阅读全文

posted @ 2006-04-24 09:29 王峰炬 阅读(347) 评论(0) 推荐(0)

excel sheet的 某列(m*n行) 快速复制到 m行n列区域
摘要:'以下代码可以利用非循环的方式,实现把[a1:a12]的数据快速复制到[b1:e3]: Private Declare Sub CopyMemory Lib "kernel32" Alias "RtlMoveMemory" (pDst As Any, pSrc As Any, ByVal By... 阅读全文

posted @ 2006-04-24 09:20 王峰炬 阅读(187) 评论(0) 推荐(0)

COPYMEMORY 实现 N维数组向M维数组的转化
摘要:'copymemory可以实现不同维数数组间的转换,如: Private Declare Sub CopyMemory Lib "kernel32" Alias "RtlMoveMemory" (pDst As Any, pSrc As Any, ByVal ByteLen As Long)... 阅读全文

posted @ 2006-04-24 09:09 王峰炬 阅读(178) 评论(0) 推荐(0)

MSHFlexGrid1使用技巧(三)[如何让鼠标在 MSHFlexGrid 中拖动也不允许选择多行]
摘要:MSHFlexGrid的selecttionMode设了by row,单击的时候是选择一行,但只要鼠标拖动也是可以选择多行: Private Sub MSHFlexGrid1_MouseMove(Button As Integer, Shift As Integer, x As Single,... 阅读全文

posted @ 2006-04-21 15:31 王峰炬 阅读(178) 评论(0) 推荐(0)

导航