请教api之GlobalMemoryStautus使用,
函数申明Private Declare Sub GlobalMemoryStatus Lib "kernel32" (lpBuffer As MEMORYSTATUS)
Private Type MEMORYSTATUS
dwLength As Long
dwMemoryLoad As Long
dwTotalPhys As Long
dwAvailPhys As Long
dwTotalPageFile As Long
dwAvailPageFile As Long
dwTotalVirtual As Long
dwAvailVirtual As Long
End Type
-------------------------
Dim b As String
b = Space(255)
b = GlobalMemoryStatus(dwTotalPhys)
txt2.Text = b
为什么老是报ByRef参数类型不符,意思是说传值参数类型不符吗?这儿该怎么传啊,