| Ver tema anterior :: Ver tema siguiente |
| Autor |
Mensaje |
philips Capt

Registrado: 16 Nov 2005Mensajes: 154
|
Publicado: Dom 22 Oct, 2006 11:46 pm Asunto: De Delphi a Builder |
|
|
Estoy pasando un programa de Delphi a Builder y me estoy volviendo loco en el empeño
Me he encontrado con esta función y estoy realmente perdido
Alguien puede hecharme una mano en la tarea?
Gracias por adelantado
Phil
var
I : Integer;
Info : TRegKeyInfo;
BB_KEY: string;
begin
BB_KEY:= 'SYSTEM\CurrentControlSet\Enum\USB\Vid_0fca&Pid_0001';
Result:= true;
with TRegistry.Create do
try
TmpPorts := TStringList.Create;
{$IFDEF DELPHI_5_OR_HIGHER}
Access := KEY_READ;
{$ENDIF}
RootKey := HKEY_LOCAL_MACHINE;
if OpenKeyReadOnly(BB_KEY) then
begin
GetKeyInfo(Info);
if Info.NumSubKeys = 0 then Result:= false;
GetKeyNames(TmpPorts);
BB_KEY:= BB_KEY + '\' + TmpPorts.Strings[0];
TmpPorts.Free;
end
else Result:= false;
CloseKey;
finally
Free;
end;
if not Result then exit;
with TRegistry.Create do
try
TmpPorts := TStringList.Create;
{$IFDEF DELPHI_5_OR_HIGHER}
Access := KEY_READ;
{$ENDIF}
RootKey := HKEY_LOCAL_MACHINE;
if OpenKeyReadOnly(BB_KEY) then
begin
GetKeyInfo(Info);
if Info.NumSubKeys = 0 then Result:= false;
GetValueNames(TmpPorts);
end
else Result:= false;
CloseKey;
finally
Free;
end;
if not Result then exit;
//Memo.Lines.Add(TmpPorts.Text);
if FindMultyStr(TmpPorts.Text, 'Filter') then
begin
Result:= false;
exit;
end;
TmpPorts.Free; |
|
| Volver arriba |
|
 |
philips Capt

Registrado: 16 Nov 2005Mensajes: 154
|
Publicado: Mar 24 Oct, 2006 10:22 pm Asunto: |
|
|
Hola
Acabo de solventar la traducción a Builder
No hace falta que os molesteis
Saludos
Phil |
|
| Volver arriba |
|
 |
|