Ver Mensaje Individual
  #7  
Antiguo 23-11-2005
Avatar de Lepe
[Lepe] Lepe is offline
Miembro Premium
 
Registrado: may 2003
Posts: 7.424
Reputación: 29
Lepe Va por buen camino
Código Delphi [-]
procedure Tsilfpe0001.T_BOPEBeforePost(DataSet: TDataSet);
begin
   if not(T_BOPE.FieldByName('bope_pedi_serie').IsNull) and not(T_BOPE.FieldByName('bope_pedi_numero').IsNull) then
   begin
//**************************************
  if T_PEDI.State in dsEditModes then
    T_PEDI.Post // me aseguro de que se guarda antes la maestra.
//**************************************
    if T_BOPE.State = dsInsert then
    begin
      T_BOPE_PRE_INSERT;
      silfse0000.Trigger_Insert(DataSet);
      sistema_lw_trigger_bope  := 'INSERT';
    end;
    if T_BOPE.State = dsEdit then
    begin
      T_BOPE_PRE_UPDATE;
      silfse0000.Trigger_Update(DataSet);
      sistema_lw_trigger_bope  := 'UPDATE';
    end;
   end
   else
   begin
    T_BOPE.Cancel;
    Abort;
   end;
end;

Lo mismo para la tabla Depe.

Prueba eso y si persiste los problemas, ya despues nos metemos con otras dudas que tengo sobre el código.

saludos
__________________
Si usted entendió mi comentario, contácteme y gustosamente,
se lo volveré a explicar hasta que no lo entienda, Gracias.
Responder Con Cita