How to use APIs in VBs

  • Thread starter Thread starter FE
  • Start date Start date
F

FE

Hi,

I would liket to know if and how to use Windows APIs in .vbs files.

I need to read a .ini file with getprivateprofilestring from .vbs ...

Thanks

FE
 
FE said:
I would liket to know if and how to use Windows APIs in .vbs
files.

I need to read a .ini file with getprivateprofilestring from .vbs
...

This is a VB.NET group (see group name).
 
Declare the function in the dll that you want like this for example.

Private Declare Function SendMessage Lib "user32.dll" Alias "SendMessageA"
(ByVal hWnd As IntPtr, ByVal wMsg As Int32, ByVal wParam As Int32, ByVal
lParam As Int32) As Int32

Const WM_VSCROLL As Int32 = &H115

Const SB_LINEDOWN As Int32 = 1

Const SB_LINEUP As Int32 = 0


--
Regards - One Handed Man

Author : Fish .NET & Keep .NET
=========================================
This posting is provided "AS IS" with no warranties,
and confers no rights.
 
FE said:
I would liket to know if and how to use Windows APIs in .vbs files.

I need to read a .ini file with getprivateprofilestring from .vbs ...

This is a VB.NET language group. Please turn to this ng:

news://news.microsoft.com/microsoft.public.scripting.vbscript
 
LOL, wrong standard reply.....


Herfried K. Wagner said:
This is a VB.NET language group. Please turn to this ng:

news://news.microsoft.com/microsoft.public.scripting.vbscript
 
The OP cross-posted both a VB.Net and VB Classic group. Hence, whatever your
reply, it would be out-of-place in one of the 2 groups.

As it is, no one is quite sure whether the OP wanted a .Net or a VB6 answer

Tony Proctor
 
Tony Proctor said:
The OP cross-posted both a VB.Net and VB Classic group.

Ooops. I didn't realize that the post was a crosspost.
Hence, whatever your reply, it would be out-of-place
in one of the 2 groups.

As it is, no one is quite sure whether the OP wanted a .Net or
a VB6 answer

He wanted a VBScript solution.
 
40 love next, then Deuce !!!!


;-D



Tony Proctor said:
The OP cross-posted both a VB.Net and VB Classic group. Hence, whatever your
reply, it would be out-of-place in one of the 2 groups.

As it is, no one is quite sure whether the OP wanted a .Net or a VB6 answer

Tony Proctor
 
An invalid crosspost has occurred, into VB.NET and VB6-.

--
HTH,
-- Tom Spink, Über Geek

Please respond to the newsgroup,
so all can benefit

"Maybe it's a game called 'Punish the User'"
 
Back
Top