anthonycosson
Messages postés106Date d'inscriptionmercredi 30 mars 2005StatutMembreDernière intervention20 novembre 2009
-
23 mars 2006 à 14:29
anthonycosson
Messages postés106Date d'inscriptionmercredi 30 mars 2005StatutMembreDernière intervention20 novembre 2009
-
23 mars 2006 à 16:05
bonjour , alors voici un bout de code de ma dll
:
for(
int i=0;i<8;i++)
{
debit=tab[i];
for(
int y=0;y<9;y++)
{
DCB *ladcb;
if(!GetCommState(h_com,ladcb))
{
CloseHandle(h_com);
return 8;
}
parite=tab1[y][1];
bitstop=tab1[y][0];
if(debit==300)
ladcb->BaudRate=CBR_300;
if(debit==600)
ladcb->BaudRate=CBR_600;
if(debit==1200)
et voici l'erreur que j'ai lorsque la dll est utilisé
************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
at GetCommState(Void* , _DCB* )
at lecturecodebar.liaison.param()
at lecturecodebar.liaison.recherche()
at lecturecodebar.liaison.connection()