帶指針的windows api的調用 [金字塔]
- 咨詢內容:
我這幾天一直在測試兩個windows api函數,vb里可以用,但在金字塔vbs里我一直測試不成功,原因是vbs里面沒有byval,請斑竹能幫我重寫一下嗎?vb6的代碼是:Option Explicit
Private Declare Function lstrcpyn Lib "kernel32" Alias "lstrcpynA" _ (DesStr As Any, _ SrcStr As Any, _ ByVal Maxlen As Long) As LongPrivate Declare Sub RtlMoveMemory Lib "kernel32" (lpvDest As Any, lpvSource As Any, _ ByVal cbCopy As Long)
Dim sData As StringDim lShareData1 As String
Dim ss(1) As DoubleDim lShareData2(1) As Double
Private Sub Form_Load()lShareData1 = "sdfa" sData = String(&H100, vbNullChar) Call lstrcpyn(ByVal sData, ByVal lShareData1, &H100)Debug.Print sData
lShareData2(0) = 1.1lShareData2(1) = 2.2 Call RtlMoveMemory(ByVal VarPtr(ss(0)), ByVal VarPtr(lShareData2(0)), 32)Debug.Print ss(0) & " " & ss(1)End Sub - 金字塔客服:
帶指針是做不到的,你可以把你的需求詳細描述一下,我們看看還有沒有一些變通的解決辦法
- 用戶回復:
vba從外面跨進程交換大量數據,除了用文件,還有沒有更快的交換通道或api,最后用通過內存?
- 網友回復:
試試數據庫呢?
有思路,想編寫各種指標公式,程序化交易模型,選股公式,預警公式的朋友
可聯系技術人員 QQ: 1145508240 進行 有償 編寫!(不貴!點擊查看價格!)
相關文章
-
沒有相關內容