Foros Club Delphi

Foros Club Delphi (https://www.clubdelphi.com/foros/index.php)
-   OOP (https://www.clubdelphi.com/foros/forumdisplay.php?f=5)
-   -   extraer un valor de un array (https://www.clubdelphi.com/foros/showthread.php?t=69917)

gio013 18-09-2010 02:18:46

extraer un valor de un array
 
holaxxx
se supone que en un array llega por usb y uso el componente jedi para trabajar el usb ,el array viene en integer,
la pregunta es.....¿como hago para utilizar el valor del array?
esto es lo que tengo...
Código Delphi [-]
procedure TForm1.Lectura(HidDev: TJvHidDevice; ReportID: Byte; const Data: Pointer; Size: Word);
var
  I: Integer;
  Str: string;
  Recibe: array [0..1] of string;

begin
  for I := 0 to Size - 1 do
    begin
    Recibe[i] := string(PChar(Data)[i]);
    Str :=Format('%.2x ', [Cardinal(PChar(Data)[i])]);
    memo1.Text:=memo1.Text+chr(13)+chr(10)+ Recibe[0];
    end;
end;

graxxx por leer...
:)

Neftali [Germán.Estévez] 20-09-2010 10:52:06

No acabo de entender muy bien qué quieres decir con "como hago para utilizar el valor del array". :confused::confused:

Ya lo estás utilizando:

Código Delphi [-]
  Recibe[i] ...

¿Para qué quieres utilizarlo? ¿Qué necesitas hacer con él?


La franja horaria es GMT +2. Ahora son las 08:50:15.

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Traducción al castellano por el equipo de moderadores del Club Delphi