Corretta apertura esclusiva dei files
git-svn-id: svn://10.65.10.50/trunk@1348 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
40787a314c
commit
23c4652cd3
@ -182,17 +182,10 @@ bool CG4100_App::sort_mov()
|
||||
if (!set_parms())
|
||||
return FALSE;
|
||||
|
||||
TSystemisamfile mov(LF_MOV);
|
||||
TSystemisamfile rmov(LF_RMOV);
|
||||
TSystemisamfile rmoviva(LF_RMOVIVA);
|
||||
|
||||
if (mov.open(_excllock) || rmov.open(_excllock) ||
|
||||
rmoviva.open(_excllock))
|
||||
{
|
||||
warning_box("Gli archivi sono in uso. Operazione interrotta");
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
TSystemisamfile mov(LF_MOV); mov.open(_excllock);
|
||||
TSystemisamfile rmov(LF_RMOV); rmov.open(_excllock);
|
||||
TSystemisamfile rmoviva(LF_RMOVIVA); rmoviva.open(_excllock);
|
||||
|
||||
mov.indexoff(); rmov.indexoff(); rmoviva.indexoff();
|
||||
mov.first();
|
||||
|
||||
@ -342,13 +335,15 @@ bool CG4100_App::sort_sal()
|
||||
if (!set_parms())
|
||||
return FALSE;
|
||||
|
||||
TSystemisamfile saldi(LF_SALDI); saldi.open(_excllock);
|
||||
TLocalisamfile rmov(LF_RMOV);
|
||||
TLocalisamfile causali(LF_CAUSALI);
|
||||
TLocalisamfile mov(LF_MOV);
|
||||
TSaldo_agg sal;
|
||||
|
||||
FILE* fp = fopen ("__sal__.sav","w");
|
||||
fclose(fp);
|
||||
|
||||
TLocalisamfile rmov(LF_RMOV);
|
||||
TLocalisamfile mov(LF_MOV);
|
||||
TLocalisamfile causali(LF_CAUSALI);
|
||||
TSaldo_agg sal;
|
||||
int gruppo, conto;
|
||||
const int year = atoi(_year);
|
||||
long oldnumreg = 0L, sottoconto;
|
||||
@ -423,6 +418,7 @@ bool CG4100_App::sort_sal()
|
||||
sal.registra();
|
||||
|
||||
remove("__sal__.sav");
|
||||
saldi.close();
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user