Thank you for being a valued part of the CNET community. As of December 1, 2020, the forums are in read-only format. In early 2021, CNET Forums will no longer be available. We are grateful for the participation and advice you have provided to one another over the years.

Thanks,

CNET Support

General discussion

Import DLL in Visual Basic

Mar 19, 2007 4:41AM PDT

While this has nothing to do with Web scripting, it seems the best place.
I am trying to control stepper motors using a Visual Basic program. Since Visual Basic cannot access the parallel port, I have to use a DLL. So the questions are: Where can I get a DLL to access the parallel port and How can I use it in Visual Basic?

Any help is appreciated.

Discussion is locked

- Collapse -
Extract and link.
Mar 19, 2007 4:44AM PDT

"
For Windows 95/98/NT/2000/Me/Xp

*

Inpout32.dll is compatible with my Win9x inpout32.dll (below) but works under all Windows editions from Win95/98/Me to WinNT/2000/XP. For Windows NT etc., a kernel mode device driver is embedded in the DLL in binary form. Freeware. A big thank you to LOGIX4U for coming up with this and making it available. For testing inpout32.dll in Visual Basic 6, see my example program Test_inpout32_vb6.zip. For testing inpout32.dll in Visual Basic .NET, see my example program Test_inpout32_vbdotnet.zip.
"
From http://www.lvr.com/parport.htm

- Collapse -
Extract? Link?
Mar 22, 2007 2:41AM PDT

So I downloaded the inpout32.dll and placed it in the system folder. I tried to add a reference to the file, but the program said it couldn't be added because it was not a valid assembly or COM component. What's the code to link or import a DLL into a program?

- Collapse -
Seems not going to work for you.
Mar 22, 2007 2:57AM PDT

Sorry but it worked fine for me. Good luck with finding an alternative.

Bob