Hi,
Following sample GPF's in HB_Uncompress():

//------------------------------
PROCEDURE Main
LOCAL cUncompressed,cCompressed

cUncompressed:=MemoRead("Uncompressed.txt")
nLen:=HB_CompressBuflen( Len( cUncompressed ) )

cCompressed:=HB_Compress( cUncompressed )

cUncompressed:=HB_Uncompress( nLen, cCompressed ) // GPF Here

RETURN
//------------------------------

Uncompressed.txt is attached.

Patrick
#include "winfakt.ch"

Function wfScript_wfAfronden()
LOCAL f:=1,oIni,nAfr
LOCAl lRetu

nAfr:=InitsD(12)

lRetu:=MsgGet("Afronden","Op hoeveel decimalen afronden:",@nAfr)
IF !lRetu
   RETURN NIL
ENDIF

Msg(1,"Afronden  (Verkoop)")
sUseDB(d_Dossier+"V1"+cJaar+".SOC",,"cAlias")
WHILE cAlias->(!Eof())
   sRLock("cAlias")
   cAlias->BDR1 :=Round(cAlias->BDR1 ,nAfr)
   cAlias->BDR2 :=Round(cAlias->BDR2 ,nAfr)
   cAlias->BDR3 :=Round(cAlias->BDR3 ,nAfr)
   cAlias->BDR4 :=Round(cAlias->BDR4 ,nAfr)
   cAlias->BDR5 :=Round(cAlias->BDR5 ,nAfr)
   cAlias->NET1 :=Round(cAlias->NET1 ,nAfr)
   cAlias->NET2 :=Round(cAlias->NET2 ,nAfr)
   cAlias->NET3 :=Round(cAlias->NET3 ,nAfr)
   cAlias->NET4 :=Round(cAlias->NET4 ,nAfr)
   cAlias->NET5 :=Round(cAlias->NET5 ,nAfr)
   cAlias->OPEN :=Round(cAlias->OPEN ,nAfr)
   cAlias->LEEG :=Round(cAlias->LEEG ,nAfr)
   cAlias->LEEGG:=Round(cAlias->LEEGG,nAfr)
   SKIP
ENDDO
sCommit("cAlias")
cAlias->(dbCloseArea())




Msg(,"Afronden (Verkoopdetail)")
sUseDB(d_Dossier+"V2"+cJaar+".SOC",,"cAlias")
cAlias->(dbEval({||sRLock("cAlias"),;
                     cAlias->NETTO:=Round(cAlias->NETTO,nAfr),;
                     cAlias->BRUTO:=Round(cAlias->BRUTO,nAfr),;
                     cAlias->LEEG :=Round(cAlias->LEEG ,nAfr);
                     }))
sCommit("cAlias")
cAlias->(dbCloseArea())




Msg(,"Afronden (Bank)")
sUseDB(d_Dossier+"BANK"+cJaar+".SOC",,"cAlias")
cAlias->(dbEval({||sRLock("cAlias"),;
                     cAlias->BEDRAG:=Round(cAlias->BEDRAG,nAfr);
                     }))
sCommit("cAlias")
cAlias->(dbCloseArea())




Msg(,"Afronden (Aankoop)")
sUseDB(d_Dossier+"AANK"+cJaar+".SOC",,"cAlias")
WHILE cAlias->(!Eof())
   sRLock("cAlias")
   cAlias->OPEN   :=Round(cAlias->OPEN   ,nAfr)
   cAlias->NETTO  :=Round(cAlias->NETTO  ,nAfr)
   cAlias->BRUTO  :=Round(cAlias->BRUTO  ,nAfr)
   cAlias->LEEG   :=Round(cAlias->LEEG   ,nAfr)
   cAlias->BTW_59 :=Round(cAlias->BTW_59 ,nAfr)
   cAlias->BTW_81 :=Round(cAlias->BTW_81 ,nAfr)
   cAlias->BTW_55 :=Round(cAlias->BTW_55 ,nAfr)
   cAlias->BTW_82 :=Round(cAlias->BTW_82 ,nAfr)
   cAlias->BTW_56 :=Round(cAlias->BTW_56 ,nAfr)
   cAlias->BTW_82B:=Round(cAlias->BTW_82B,nAfr)
   cAlias->BTW_83 :=Round(cAlias->BTW_83 ,nAfr)
   cAlias->BTW_86 :=Round(cAlias->BTW_86 ,nAfr)
   cAlias->BTW_87 :=Round(cAlias->BTW_87 ,nAfr)
   cAlias->BTW_63 :=Round(cAlias->BTW_63 ,nAfr)
   cAlias->BTW_84 :=Round(cAlias->BTW_84 ,nAfr)
   cAlias->BTW_85 :=Round(cAlias->BTW_85 ,nAfr)
   SKIP
ENDDO
sCommit("cAlias")
cAlias->(dbCloseArea())


Msg(0)
sInfo("Alles afgerond...")


RETU NIL
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
xHarbour-developers mailing list
xHarbour-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/xharbour-developers

Reply via email to