The data returned in SerialPortNG.ReadNextClusterAsString, is it a buch of
chars at a time, or just one at a time?
If its a bunch of them at a time, you will need to do a conversion one char
at at time in a loop.
i.e. for x:=0 to length(sRaw) do
begin
ivalue:= ORD(sRaw[x])) ;
end;
something along those lines....I didnt write that in Delphi, I just did it
from memory but it should help a bit....I hope.
Jeremy
On Fri, Aug 5, 2011 at 8:43 AM, Steven Knight <[email protected]>wrote:
> You might need to use the ORD function byte by byte****
>
> ** **
>
> Steven****
>
> ** **
>
> *From:* [email protected] [mailto:[email protected]]
> *On Behalf Of *Marshland Engineering
> *Sent:* Thursday, 4 August 2011 7:47 p.m.
> *To:* [email protected]
> *Subject:* Re: [DUG] HEX to decimal****
>
> ** **
>
> ****
>
> Been there done that ****
>
> ****
>
> edit2.text := IntToStr(StrToInt('$' + sRaw));****
>
> Result '[' is not a valid integer. ****
>
> ****
>
> ****
>
> ****
>
> ****
>
> **********************************************************************
> This email and any files transmitted with it are confidential and
> intended solely for the use of the individual or entity to whom they
> are addressed. If you have received this email in error please notify
> the sender of the message.
>
> This footnote also confirms that this email message has been swept by
> MIMEsweeper for the presence of computer viruses.
>
> www.ecan.govt.nz
> **********************************************************************
>
> _______________________________________________
> NZ Borland Developers Group - Delphi mailing list
> Post: [email protected]
> Admin: http://delphi.org.nz/mailman/listinfo/delphi
> Unsubscribe: send an email to [email protected] with Subject:
> unsubscribe
>
_______________________________________________
NZ Borland Developers Group - Delphi mailing list
Post: [email protected]
Admin: http://delphi.org.nz/mailman/listinfo/delphi
Unsubscribe: send an email to [email protected] with Subject:
unsubscribe