hej
ik heb windows 7 en heb al geprobeert om mijn printerpoort aan te sturen
maar het lukt mij niet
ik schrijf in vs2010 en die geeft mij telkens een foutmelding
ook als ik een io.dll in systeem en in de programmamap het gezet
en deze code heb toegevoegd:
Option Strict Off
Option Explicit On
Module io
Public Declare Sub PortOut Lib "IO.DLL" (ByVal Port As Integer, ByVal Data As Byte)
Public Declare Sub PortWordOut Lib "IO.DLL" (ByVal Port As Integer, ByVal Data As Integer)
Public Declare Sub PortDWordOut Lib "IO.DLL" (ByVal Port As Integer, ByVal Data As Long)
Public Declare Function PortIn Lib "IO.DLL" (ByVal Port As Integer) As Byte
Public Declare Function PortWordIn Lib "IO.DLL" (ByVal Port As Integer) As Integer
Public Declare Function PortDWordIn Lib "IO.DLL" (ByVal Port As Integer) As Long
Public Declare Sub SetPortBit Lib "IO.DLL" (ByVal Port As Integer, ByVal Bit As Byte)
Public Declare Sub ClrPortBit Lib "IO.DLL" (ByVal Port As Integer, ByVal Bit As Byte)
Public Declare Sub NotPortBit Lib "IO.DLL" (ByVal Port As Integer, ByVal Bit As Byte)
Public Declare Function GetPortBit Lib "IO.DLL" (ByVal Port As Integer, ByVal Bit As Byte) As Boolean
Public Declare Function RightPortShift Lib "IO.DLL" (ByVal Port As Integer, ByVal Val As Boolean) As Boolean
Public Declare Function LeftPortShift Lib "IO.DLL" (ByVal Port As Integer, ByVal Val As Boolean) As Boolean
Public Declare Function IsDriverInstalled Lib "IO.DLL" () As Boolean
End Module
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Call PortOut(&H378, 1)
End Sub
hij geeft deze foutcode aan mij als ik op de knop druk:
Unable to load DLL 'IO.DLL': Kan opgegeven module niet vinden. (Exception from HRESULT: 0x8007007E)
wat moet ik doen
Een plaatje dat jij op je PC hebt staan kunnen wij hier niet zien. Gebruik het uploadarchief of iets dergelijks.
Ik heb even een soortgelijk programma in elkaar gezet. Na het kopiëren van de dll in de bin map krijg ik geen "unable to load", maar een melding van invalid image format. Blijkbaar was mijn dll corrupt of zo. Ik raad je aan nog eens heel goed te kijken of de dll wel in de juiste map staan (bin/debug of bin/release) en of je wel de juiste projectmap te pakken hebt (ik had net twee versies gemaakt. De DLL stond in de map van versie 1 terwijl ik steeds versie 2 aan het uitproberen was)
timmie
niet met me uitspraken(of opmerkingen) eens mail me.K8048 guide
waarschijnlijk is je DLL corrupt
wat je ook nog kan proberen, als je de dll in je win32map hebt zitten.
run je app vanuit "protected space".
timmie
niet met me uitspraken(of opmerkingen) eens mail me.K8048 guide