🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #17750

Re: writefile

#17750
From: Holy Punk
Date: Mon, 03 Mar 2003 18:33
15 lines
1393 bytes
"gotnoname" <nospam.rtsen@texondevices.com> wrote in message
news:3E63C380.7080200@texondevices.com...
> for my serial communication part of my program I would like to send a
> character to COM1.
>    WriteFile(hComm, "C", 1, &dwBytesRead, NULL);
>
> If I want to send a character using its ASCII value, how do I do that?
> For instance if I want to send an ACK (006) or NAK (021).

char c = 006;
unsigned int uiBytesWrtn;
WriteFile( hComm, &c, 1, &uiBtsWrtn, 0 );

Best regards,
Holy Punk.
Technical Details
Message-ID: <3e63ca1d$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-06!sn-xit-08!supernews.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail
References: <3E63C380.7080200@texondevices.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,25c5ee8d35949251
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-03-04 13:52:00 PST
From: "Holy Punk" <Holy_Punk@hotmail.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3E63C380.7080200@texondevices.com>
Subject: Re: writefile
Date: Mon, 3 Mar 2003 13:33:27 -0500
Lines: 17
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
NNTP-Posting-Host: 142.58.249.209
Message-ID: <3e63ca1d$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1046727197 142.58.249.209 (3 Mar 2003 13:33:17 -0800)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-06!sn-xit-08!supernews.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail