Ver Mensaje Individual
  #9  
Antiguo 03-12-2008
javi.donvito javi.donvito is offline
Registrado
 
Registrado: may 2005
Posts: 6
Reputación: 0
javi.donvito Va por buen camino
Gracias por la bienvenida y por responderme tan rápido. Y disculpar por el estilo del primer mensaje.

He realizado las pruebas que me habéis indicado pero sigo tendiendo problemas

El programa me genera la siguiente excepción:

'... exception class EConvertError with message "2008-12-03" is not a valid date'

No entiendo porqué, es un formato de fecha válido. Tampoco entiendo que me lo genere en ´la segunda linea

FechaActual :=StrToDate(FormatDateTime ('yyyy/mm/dd',now));

Siguiendo con las pruebas y pasando la fecha de las formas que me habias comentado

Parameters.ParamByName('pFecha').Value:=now; {o poniedo FechaActual}
me sigue generando el mismo error de ayer

Project rRecibos.exe raised exception class EOleException with message Microsoft ODBC SQL Server Drivers Optional feature not implemented

He probado y dado un motón de vueltas y me sigue dando problemas para pasar las fechas ¿Alguna sugerencia?

Gracias

Código Delphi [-]
procedure TForm1.btnActualizaClick(Sender: TObject);
Var
  FechaActual : TDateTime;
begin
  DateSeparator :='-';

 (*  En la siguiente linea
  FechaActual :=StrToDate(FormatDateTime ('yyyy/mm/dd',now));
  me sale el error
       '... exception class EConvertError with message "2008-12-03" is not a valid date'
 *)
  with ADOQCambiar do
  begin
    SQL.Clear;

    SQL.Add ('UPDATE CuotasEmitidas SET FecSituacion = Fecha'+
            'WHERE CuotasEmitidas.CodPers = 1801 ' +
            'AND CuotasEmitidas.NumRecibo = 810375');

    Parameters.ParamByName('pFecha').Value:=StrToDate(FormatDateTime ('yyyy/mm/dd',now));
    ExecSQL;

 end;
end;
Responder Con Cita