Saludos
Cita:
|
Empezado por Nelly
una fecha(Pero en la fecha hay una condición, quiero que muestre solo la fecha que eligire en el combo, no quiero que me arroje 10 o más fechas, solo la fecha del combo seleccionada.),..
|
No estoy seguro, si acabo de entender
Código Delphi
[-]
procedure Tfrmrep.btnbuscarClick(Sender: TObject);
var
evento:integer;
begin
evento:=cmbevento.keyvalue;
if evento in [1,2]>'' then begin qryrep.Active:=false;
qryrep.SQL.Clear;
qryrep.SQL.Add('select * from eventos');
qryrep.SQL.Add('where cve_evento=:cve_evento');
qryrep.ParamByName('cve_evento').AsInteger; qryrep.Active:=true;
end else begin
if (cmbevento.KeyValue>'') or (cmbfechevento.DateTime>'') or (cmbmunicipio.KeyValue>-1) then begin
qryrep.SQL.Clear;
qryrep.SQL.Add('select * from eventos where cve_mpo=:cve_mpo ');
qryrep.SQL.Add('where cve_evento starting with: clave and ');
qryrep.SQL.Add('fecha_evento starting with: fecha and ');
qryrep.ParamByName('clave').AsInteger:=cmbevento.KeyValue;
qryrep.ParamByName('fecha').AsDateTime; qryrep.ParamByName('cve_mpo').AsInteger:=cmbmunicipio.KeyValue;
qryrep.Active:=true;
end else begin
ShowMessage('');
end;
end;
end;
No aporto mas hasta aclara esos puntos