E fatura son bakiye kuralı
<blockquote> <p><code>sub ProcessEvent(App)<br /> ST_ClRef = App.Doc.FieldAsInteger("ARP_LOGICALREF")<br /> ST_CHRRef = CStr(ST_ClRef)<br /> BAKIYE = App.UQUERY_GETFLD(60,"SUM(DEBIT)-SUM(CREDIT)",24,6,FALSE,"CARDREF ="+ST_CHRRef+" AND TOTTYP = 1" )<br /> App.Doc.WriteStartElement "ADDITIONALDOCUMENTS/ADDITIONALDOCUMENT"<br /> App.Doc.WriteElementString "ID",Replace(cstr(BAKIYE),",",".")<br /> App.Doc.WriteElementString "ISSUEDATE", Year(Date) & "-" & Right("0" & Month(Date),2) & "-" & Right("0" & Day(Date), 2)<br /> App.Doc.WriteElementString "DOCUMENTTYPE", "BAKIYE"<br /> App.Doc.WriteEndElement<br /> App.Doc.SaveData<br /> end sub</code></p> <p>Xslt Kodu<br /> <br /> <code><br /><br /> <xsl:for-each select="//n1:Invoice/cac:AdditionalDocumentReference"><br /> <xsl:if test ="cbc:DocumentType = 'BAKIYE'"><br /> <b>Son Cari Hesap Bakiyesi : </b><br /> <b><br /> <xsl:value-of select="cbc:ID"/><br /> </b><br /> <b> TL </b><br /> </xsl:if></code></p> </blockquote>
0 Yorum