ChaveTech
asked on
Parallel Port access with C#
I'm looking for some help on writing to the parallel port within WinXP Pro using C#. I'm not sure how this is done and I can't find any substantial resources online. All I want to do is be able to write a byte, that's it, nothing else.
Thanks
Thanks
ASKER
I've been to that site and have tried it, but it's not working. I don't know if the DLL the author provides is valid. I don't have a problem writing it in C++, but I'm not familiar with writing in COM. Do you have any suggestions?
ChaveTech,
With com, all you need to do is create an ATL com object. Use the template. Add a method called to the COM interface you create called WriteParallelByte which takes in a byte (as an int). You can then simply include this in a C# project by adding a reference to the COM object (dll). .NET Studio will then automatically create an interop dll that will allow you to instantiate this com object and make the call.
With com, all you need to do is create an ATL com object. Use the template. Add a method called to the COM interface you create called WriteParallelByte which takes in a byte (as an int). You can then simply include this in a C# project by adding a reference to the COM object (dll). .NET Studio will then automatically create an interop dll that will allow you to instantiate this com object and make the call.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Windows knows how to Map files like this? I had no idea....
http://www.codeproject.com/csharp/csppleds.asp?df=100&forumid=21021&exp=0&select=799135
In addition, you could always write it in a C++ com and interop to it.