|
-
Oct 28th, 2004, 07:53 PM
#1
Thread Starter
Lively Member
Convert CreateFile to VB
I have created this C function to send data through a serial port.
Is there a VB version of these function calls?
hnd = CreateFile ("COM1:",GENERIC_READ | GENERIC_WRITE,0,NULL,OPEN_EXISTING,FILE_ATTRIBUTE_NORMAL,NULL);
Status = SetCommState(hnd,&MyDCB);
if (!Status)
{
Status = GetLastError();
}
Status = WriteFile (hnd, string, lstrlen(string), &count, NULL);
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|