|
Publicité ' | |||||||||||||||||||||||
|
|
#1 | ||
|
Invité de passage
![]() Inscription : août 2007 Messages : 2 ![]() |
Bonjour,
j'essaye d'ecrire mon premier programme en C++ ILe, et je suis bloqué au niveau de la gestion des sous-fichier. J'ai créé un fichier ecran comportant 2 "RECORD" (enregistrement); le premier correspond à un ensemble de champ et le second est un sous-fichier (SFL). Comment faire pour afficher le sous-fichier après avoir réaliser les entrées correspondante à l'enregistrement N° 1? Ci-après un bout de code: Code :
|
||
|
|
00
|
|
|
#2 |
|
Membre du Club
![]() Jean-Pierre LarocheInscription : octobre 2005 Messages : 41 ![]() |
void TRT_SFL ()
{ int I_Ligne ; int I_LignP ; _Rformat(dspf,"FMT01CTL"); indicator_area[I91] = IND_OF ; indicator_area[I96] = IND_ON ; _Rwrite(dspf,DISPLAY_CTL,I_LGCTL); indicator_area[I96] = IND_OF ; _Rformat(dspf,"FMT02SFL"); /*--------------- PAGE AV ---------------*/ if (CLAVIER == ENTER ) { FK = _Rlocate(P_PHY,K_BUF_PHY,I_LGKEY,__NO_LOCK|__START); FK = _Rlocate(P_PHY,K_BUF_PHY,I_LGKEY,__NO_LOCK|__KEY_GE); FK = _Rreadp(P_PHY,BUF_PHY,I_LGPHY,__NO_LOCK) ; } if (CLAVIER == PG_AV ) FK = _Rreadp(P_PHY,BUF_PHY,I_LGPHY,__NO_LOCK) ; CPF(); /*--------------- PAGE AR ---------------*/ if (CLAVIER == PG_AR ) { I_Ligne = 0 ; if (indicator_area[I77] == IND_OF ) I_LignP = (I_NBLIG * 2 ) + 1 ; else I_LignP = I_NBLIG + 1 ; do { FK = _Rreadp(P_PHY,BUF_PHY,I_LGPHY,__NO_LOCK) ; CPF(); if ( IND != IN33 ) ++I_Ligne ; } while ((IND != IN33 ) && (I_Ligne != I_LignP)) ; if (FK->num_bytes == EOF ) FK = _Rlocate(P_PHY,K_BUF_PHY,I_LGKEY,__NO_LOCK|__START); } /*--------------- AFFICHAGE ---------------*/ indicator_area[I77] = IND_OF; FK = _Rreadn(P_PHY,BUF_PHY,I_LGPHY,__NO_LOCK); CPF(); I_Ligne = 0 ; do { if (IND != IN33) { CHARGE_SFL(); _Rwrited(dspf,DISPLAY_SFL,I_LGSFL, ++ I_Ligne); indicator_area[I91] = IND_ON; FK = _Rreadn(P_PHY,BUF_PHY,I_LGPHY,__NO_LOCK); CPF(); } } while ((IND != IN33) && ( I_Ligne != I_NBLIG)) ; if (FK->num_bytes == EOF ) { FK = _Rlocate(P_PHY,K_BUF_PHY,I_LGKEY,__NO_LOCK|__LAST); indicator_area[I77] = IND_ON; } } |
|
|
00
|
|
|
#3 |
|
Invité de passage
![]() Inscription : août 2007 Messages : 2 ![]() |
Merci, pour la fonction, je vais essayer de l'adapter à ma sauce.
ou a défaut, je vais me tourner vers le RPG |
|
|
00
|
Copyright © 2000-2012 - www.developpez.com