Hi,
I'm trying to play a MIDI note using a VB script with the following codes lines:
Private Declare Function midiOutShortMsg Lib "winmm.dll" (ByVal hMidiOut , ByVal dwMsg)
Private Declare Function midiOutOpen Lib "winmm.dll" (lphMidiOut, ByVal uDeviceID, ByVal dwCallback, ByVal dwInstance, ByVal dwFlags)
It seems like "Private Declare Function" is not acceptable,
How can i include win libraries ?
VB Script Problem
-
- HouseBot Guru Extraordinaire
- Posts: 1121
- Joined: Tue Sep 28, 2004 7:49 am
- Location: The Netherlands
It is possible to call for dll's from vbscript. Not sure though if this is what you need. A code example below:
OSPOP3 is a registered dll in the system32 directory and can be accessed accordingly.
OSPOP3 is a registered dll in the system32 directory and can be accessed accordingly.
Code: Select all
Dim objPOP3
Set objPOP3 = CreateObject("OSPOP3.Session")
objPOP3.RaiseError = False
If objPOP3.OpenPOP3(AccountServer(Account), 110, AccountUser(Account), Passwd) Then
objPOP3.GetMailboxSize
EMailCountTotal = objPOP3.MessageCount