Ver Mensaje Individual
  #13  
Antiguo 12-03-2010
Avatar de Caral
[Caral] Caral is offline
Miembro Premium
 
Registrado: ago 2006
Posts: 7.659
Reputación: 25
Caral Va por buen camino
Hola
Se nota que no tengo nada que hacer jejeje.
Este codigo tal vez te parezca interesante, mira como se reduce todo:
Código Delphi [-]
procedure TForm3.BitBtn4Click(Sender: TObject);
var
Texto1, Texto2: String;
i: Integer;
Comp: TComponent;

begin
 Texto1:= 'select NOMBRES,MATRICULA,CLAVE,A';
 Texto2:= 'from 20092 where clave = '+quotedstr(combobox1.Text)+' order by nombres asc';
 with datam.Query1 do begin;
 close;
 sql.Clear;

 for i := 1 to 10 do begin  // 10 radioButton
 comp := FindComponent('radioButton' + IntToStr(i));

 If TradioButton(comp).Checked = true then
 begin
 sql.Text:= Texto1+IntToStr(i)+Texto2;
 open;
 edit;
 end;

end;
end;
end;
Siempre me acuerdo que el Maestro Neftali fue el que me lo enseño.
Saludos
__________________
Siempre Novato
Responder Con Cita