Librería | Clase | Metodo |
AhoraConta | Conta | GeneraFactAcreedor |
Implementación:
Function GeneraFactAcreedor( aObjeto As Object, aSerie As Long, aFechaFact As Date, Optional aNumFactProv As String = "") As Object
Descripción:
Genera y devuelve un objeto factura de acreedor.
Código VB6:
' Generar Factura Rectificativa
Set lFrm = New frmDatosFactRect
lFrm.Carga eTipoSerie_Proveedor
If lFrm.OK Then
lSerie = lFrm.Serie
lMotivo = lFrm.MotivoRect
lFecha = lFrm.Fecha
lNumFactProv = lFrm.NumFactProv
Set lObj = gForm.EObjeto.Obj ' la factura origen
Set lFactAcreedor = gCn.AhoraProceso("GeneraFactAcreedor", False, lObj, lSerie, lFecha, lNumFactProv)
If lFactAcreedor Is Nothing Then
Msgbox "Error creando la factura Rectificativa"
else
Msgbox "Se ha creado la factura Rectificativa " &
lFactAcreedor.Propiedades("IdFactura")
End If
End If Código C#:
// Generar Factura Rectificativa
IfrmDatosFactRect lFrm = (IfrmDatosFactRect)gCn.AhoraProceso("DamefrmDatosFactRect", out _);
lFrm.Carga(AhoraUtil.ETipoSerie.ETipoSerie_Proveedor);
if (lFrm.OK)
{
int lSerie = lFrm.Serie;
string lMotivo = lFrm.MotivoRect;
DateTime lFecha = lFrm.Fecha;
string lNumFactProv = lFrm.NumFactProv;
IItemColeccion lObj = (gForm.Controls["EObjeto"] as IEnlaceObjetos).ObjGlobal;
IItemColeccion lFactAcreedor = (IItemColeccion)gCn.AhoraProceso("GeneraFactAcreedor", out _, lObj, lSerie, lFecha, lNumFactProv);
if ( lFactAcreedor == null )
{
MsgBox("Error creando la factura Rectificativa");
}
else
{
MsgBox("Se ha creado la factura Rectificativa " + lFactAcreedor["IdFactura"]);
}
}¿Le ha sido útil este artículo?
¡Qué bien!
Gracias por sus comentarios
¡Sentimos mucho no haber sido de ayuda!
Gracias por sus comentarios
Sus comentarios se han enviado
Agradecemos su esfuerzo e intentaremos corregir el artículo