Re: how to use vb6 dll?
- From: "Fred Taylor" <ftaylor@xxxxxxxx!REMOVE>
- Date: Thu, 12 Apr 2007 20:22:33 -0700
You should be able to use WMI directly in VFP:
*!* Let's get the CPU ID
LOCAL lcComputerName, loWMI, lowmiWin32Objects, lowmiWin32Object
lcComputerName = GETWORDNUM(SYS(0),1)
loWMI = GETOBJECT("WinMgmts://" + lcComputerName)
lowmiWin32Objects = loWMI.InstancesOf("Win32_Processor")
FOR EACH lowmiWin32Object IN lowmiWin32Objects
WITH lowmiWin32Object
? "ProcessorId: " + TRANSFORM(.ProcessorId)
ENDWITH
ENDFOR
The above code is from
http://fox.wikis.com/wc.dll?Wiki~RetrievingHardwareInformation~VFP
--
Fred
Microsoft Visual FoxPro MVP
"Mr. Server" <alxgen@xxxxxxxxxxx> wrote in message
news:EFDC2AA4-223A-4E93-8A78-3DD9AC32FA3B@xxxxxxxxxxxxxxxx
i have a simple question, how can i use my dll with functions created from
vb6 to my vfp6 application?
this is my vb function:
Public Function GetCPUID() As String
Dim oWMI, oCpu
Set oWMI = GetObject("winmgmts:")
For Each oCpu In oWMI.InstancesOf("Win32_Processor")
GetCPUID = oCpu.ProcessorID
Next
End Function
.
- Follow-Ups:
- Re: how to use vb6 dll?
- From: Mr. Server
- Re: how to use vb6 dll?
- References:
- how to use vb6 dll?
- From: Mr. Server
- how to use vb6 dll?
- Prev by Date: how to use vb6 dll?
- Next by Date: Re: how to use vb6 dll?
- Previous by thread: how to use vb6 dll?
- Next by thread: Re: how to use vb6 dll?
- Index(es):
Loading