Exemple de définition de prototypes à inclure dans les exécutables
**FREE
// =========================================================================
// Fichier: prototypes.rpgleinc
// Description: Prototypes partagés pour l'application de gestion
// Usage: /INCLUDE '/includes/prototypes.rpgleinc'
// =========================================================================
// -------------------------------------------------------------------------
// PROGRAMMES DE MAINTENANCE
// -------------------------------------------------------------------------
// Prototype: FOURN02R - Maintenance fournisseur
Dcl-Pr FOURN02R ExtPgm;
pMode Char(1); // 'C'=Création, 'M'=Modification
pCode Int(10); // Code fournisseur (0 en création)
End-Pr;
// Prototype: PRODUIT2R - Maintenance produit
Dcl-Pr PRODUIT2R ExtPgm;
pMode Char(1); // 'C'=Création, 'M'=Modification
pCode Int(10); // Code produit (0 en création)
pFourn Int(10) Options(*NoPass); // Fournisseur par défaut (optionnel)
End-Pr;
// Prototype: CLIENT02R - Maintenance client
Dcl-Pr CLIENT02R ExtPgm;
pMode Char(1); // 'C'=Création, 'M'=Modification
pCode Int(10); // Code client (0 en création)
End-Pr;
// -------------------------------------------------------------------------
// PROGRAMMES DE LISTE
// -------------------------------------------------------------------------
// Prototype: PRODUIT1R - Liste des produits
Dcl-Pr PRODUIT1R ExtPgm;
pCodeFourn Int(10) Options(*NoPass); // Filtre fournisseur (0=tous)
End-Pr;
// Prototype: CDE01R - Liste des commandes
Dcl-Pr CDE01R ExtPgm;
pCodeClient Int(10) Options(*NoPass); // Filtre client (0=toutes)
End-Pr;
// Prototype: CDE02R - Gestion lignes de commande
Dcl-Pr CDE02R ExtPgm;
pNumero Int(10); // Numéro commande (0=création)
pCodeClient Int(10); // Code client
End-Pr;
// -------------------------------------------------------------------------
// PROGRAMMES DE SÉLECTION (POPUPS)
// -------------------------------------------------------------------------
// Prototype: SELFOURN - Sélection d'un fournisseur
Dcl-Pr SELFOURN ExtPgm;
pCodeFourn Int(10); // Code fournisseur sélectionné (sortie)
End-Pr;
// Prototype: SELCLI - Sélection d'un client
Dcl-Pr SELCLI ExtPgm;
pCodeClient Int(10); // Code client sélectionné (sortie)
End-Pr;
// Prototype: SELPROD - Sélection d'un produit
Dcl-Pr SELPROD ExtPgm;
pCodeProduit Int(10); // Code produit sélectionné (sortie)
pPrixUnit Packed(8:2); // Prix unitaire du produit (sortie)
End-Pr;
// -------------------------------------------------------------------------
// UTILITAIRES
// -------------------------------------------------------------------------
// Prototype: CONFIRMER - Confirmation générique (SRVPGM)
Dcl-Pr CONFIRMER ExtPgm('CONFIRME');
pMessage Char(50); // Message à afficher
pReponse Char(1); // Réponse 'O' ou 'N' (sortie)
End-Pr;
// =========================================================================
// FIN DES PROTOTYPES
// =========================================================================


Commentaires
Enregistrer un commentaire