I'm working in Borland Delphi, and i have a few lines code in Borland C++ Builder. I would like to translate these lines into Delphi source.
unsigned char *buf=NULL;
buf=new unsigned char[SPS*2];
for (i=0; i<SPS*2; i++)
buf[i]=2;
... ....
answers=buf[2];
I would like to assign a PCHar value with this buf;
a:PCHar;
a:=buf.
Perhaps like this:
No idea what
answers
is, but, assuming it is achar
in your C++ code then you would write it like this: