// Nota:
// Gli alias 213, 613, 813 sono separati per ovvii motivi di stampa
// di valori diversi

USE 36
JOIN 37 TO 36 INTO TIPOQUA=TIPOQUA CODDITTA=CODDITTA
JOIN  9 TO 36 INTO CODDITTA=CODDITTA
JOIN  6 TO  9 ALIAS 116 INTO TIPOA=TIPOA CODANAGR=CODANAGR
JOIN  7 TO  9 INTO CODANAGR=CODANAGR
JOIN  8 TO  6 ALIAS 118 INTO CODANAGR=CODANAGR
JOIN 13 TO  8 ALIAS 113 INTO COM==COMNASC
JOIN 13 TO  6 ALIAS 213 INTO COM==COMRF(COMRES)
JOIN 13 TO  6 ALIAS 613 INTO COM==COMRES
JOIN 13 TO  6 ALIAS 813 INTO COM==COMRF
JOIN  6 TO  36  ALIAS 216 INTO TIPOA=="F" CODANAGR==RAPPR   
JOIN  8 TO 216@ ALIAS 218 INTO CODANAGR==CODANAGR 
JOIN 13 TO 218@ ALIAS 313 INTO COM==COMNASC
JOIN 13 TO 216@ ALIAS 413 INTO COM==COMRF(COMRES)
JOIN 10 TO   9  INTO CODDITTA==CODDITTA CODATT==CODATTPREV
JOIN  6 TO  10  ALIAS 316 INTO TIPOA==TIPOADS CODANAGR==CODANGRDS
JOIN 13 TO  10  ALIAS 513 INTO COM==COMCS 
JOIN 13 TO 316@ ALIAS 713 INTO COM==COMRF(COMRES)
END

DESCRIPTION
BEGIN
  36->* "Base 770"
  37->* "Basebis 770"
  9->* "Ditte"
  6->* "LF_ANAG"
  7->* "GIURIDICHE"  
  8->* "FISICHE"
  10->* "ATTIV"  
  116@->* "Comuni"
  118@->* "Comuni"
END

GENERAL
BEGIN
  OFFSET 0 0
  FONT "Roman 17cpi"
  SIZE 12
  CA "X"           
  IN 3 2
  FI 131
END                                          

SECTION BODY FIRST 40

LISTA 1
BEGIN
 KEY "Tipo anagrafica: ABILITA PERSONE FISICHE/ALTRI SOGGETTI"
 FIELD 9->TIPOA
 ITEM "F| " MESSAGE ENABLE,1@|DISABLE,2@
 ITEM "G| " MESSAGE ENABLE,2@|DISABLE,1@
 FLAGS "H"
END

STRINGA 2
BEGIN
  KEY "GRUPPO 1 - PERSONE FISICHE - CODICE FISCALE"
  PROMPT 25 1  ""
  FIELD 116@->COFI
  GROUP 1
END

LISTA 3
BEGIN
  KEY "REG.A.STATUTO.SPECIALE VA - SA -SI"
  PROMPT 93 1 ""
  ITEM "|"    
  ITEM "1|X"
  ITEM "2|"
  ITEM "3|"
  FIELD 36->RSS
  GROUP 1
END      

LISTA 4
BEGIN
  KEY "REG.A.STATUTO.SPECIALE VA - SA -SI"
  PROMPT 101 1 ""
  ITEM "|"    
  ITEM "1|"
  ITEM "2|X"
  ITEM "3|"
  FIELD 36->RSS
  GROUP 1
END

LISTA 5
BEGIN
  KEY "REG.A.STATUTO.SPECIALE VA - SA -SI"
  PROMPT 110 1 ""
  ITEM "|"    
  ITEM "1|"
  ITEM "2|"
  ITEM "3|X"
  FIELD 36->RSS
  GROUP 1
END

STRINGA 6
BEGIN
  KEY "CODICE ATTIVITA"
  PROMPT 124 1 ""
  FIELD 9->CODATTPREV
  GROUP 1
END

STRINGA 7
BEGIN
  KEY "COGNOME"
  PROMPT 25 3 ""
  FIELD 116@->RAGSOC[1,30]
  GROUP 1
END  

STRINGA 8
BEGIN
  KEY "NOME"
  PROMPT 82 3 ""
  FIELD 116@->RAGSOC[31,50]
  GROUP 1
END  

LISTA 9
BEGIN
  KEY "SESSO M"
  PROMPT 120 3 ""
  ITEM " | "
  ITEM "M|X"
  ITEM "F|"
  FIELD 118@->SESSO
  GROUP 1
END  

LISTA 10
BEGIN
  KEY "SESSO F"
  PROMPT 130 3 ""
  ITEM " | "  
  ITEM "M|"
  ITEM "F|X"
  FIELD 118@->SESSO
  GROUP 1
END  
  
STRINGA 11
BEGIN
  KEY "DATA DI NASCITA"
  PROMPT 25 5 ""
  FIELD 118@->DATANASC
  PICTURE "## ^ ##  ^^###" 
  GROUP 1
END  
  
STRINGA 12
BEGIN
  KEY "COMUNE DI NASCITA"
  PROMPT 47 5 ""
  FIELD 113@->DENCOM
  GROUP 1
END  
  
STRINGA 13
BEGIN
  KEY "PROV. DI NASCITA"
  PROMPT 103 5 ""
  FIELD 113@->PROVCOM
  GROUP 1
END  

LISTA 14
BEGIN
  KEY "EVENTI ECCEZIONALI"
  PROMPT 130 5 ""
  FIELD 116@->EVECC
  ITEM " | "
  ITEM "1|X" 
  ITEM "2| "
  ITEM "3|X"  
  GROUP 1
END
  
STRINGA 15
BEGIN
  KEY "COMUNE DI RES.FISCALE"
  PROMPT 44 7 ""
  FIELD 213@->DENCOM
  GROUP 1  
END  
  
STRINGA 16
BEGIN
  KEY "PROV DI RES.FISCALE"
  PROMPT 103 7 ""
  FIELD 213@->PROVCOM
  GROUP 1  
END  

STRINGA 17
BEGIN
  KEY "CAP"
  PROMPT 122 7 ""
  FIELD 116@->CAPRF 
  FIELD 116@->CAPRES  
  GROUP 1  
END  
  
STRINGA 18
BEGIN
  KEY "VIA di RES."
  PROMPT 44 9  ""
  FIELD 116@->INDRF
  FIELD 116@->INDRES
  GROUP 1  
END  
  
STRINGA 19
BEGIN
  KEY "NUM. CIVICO di RES."
  PROMPT 82 9 ""
  FIELD 116@->CIVRF
  FIELD 116@->CIVRES
  GROUP 1
END  
  
STRINGA 20
BEGIN
  KEY "TELEFONO - PREFISSO"
  PROMPT 102 9 ""
  FIELD 116@->PTELRF
  GROUP 1  
END
  
STRINGA 21
BEGIN
  KEY "TELEFONO - NUMERO"  
  PROMPT 114 9 ""
  FIELD 116@->TELRF   
  GROUP 1  
END

STRINGA 22 
BEGIN
  KEY "GRUPPO 2 - ALTRI SOGGETTI - CODICE FISCALE"
  PROMPT 25 11  ""
  FIELD 116@->COFI
  GROUP 2
END

LISTA 23
BEGIN
  KEY "REG.A.STATUTO.SPECIALE VA - SA -SI"
  PROMPT 93 11 ""   
  ITEM "|"
  ITEM "1|X"
  ITEM "2|"
  ITEM "3|"
  FIELD 36->RSS
  GROUP 2
END      

LISTA 24
BEGIN
  KEY "REG.A.STATUTO.SPECIALE VA - SA -SI"
  PROMPT 101 11 ""
  ITEM "|"  
  ITEM "1|"
  ITEM "2|X"
  ITEM "3|"
  FIELD 36->RSS
  GROUP 2
END

LISTA 25
BEGIN
  KEY "REG.A.STATUTO.SPECIALE VA - SA -SI"
  PROMPT 110 11 ""
  ITEM "|"  
  ITEM "1|"
  ITEM "2|"
  ITEM "3|X"
  FIELD 36->RSS
  GROUP 2
END

STRINGA 26
BEGIN
  KEY "CODICE ATTIVITA"
  PROMPT 124 11 ""
  FIELD 9->CODATTPREV
  GROUP 2
END

STRINGA 27
BEGIN
  KEY "RAGIONE SOCIALE"
  PROMPT 25 13  ""
  FIELD 116@->RAGSOC
  GROUP 2
END

LISTA 28
BEGIN
  KEY "EVENTI ECCEZIONALI"
  PROMPT 130 13 ""
  FIELD 116@->EVECC
  ITEM " | "
  ITEM "1|X" 
  ITEM "2| "
  ITEM "3|X"  
  GROUP 2
END

STRINGA 29
BEGIN
  KEY "FLAG SEDE LEGALE"
  PROMPT 31 16 ""
  FIELD 116@->VARSLORES
  GROUP 2
END

STRING 30
BEGIN
  KEY "COMUNE SEDE LEGALE "
  PROMPT 41 15 ""
  FIELD 613@->DENCOM
  GROUP 2
END

STRING 31
BEGIN
  KEY "PROV. SEDE LEGALE"
  PROMPT 122 15 ""
  FIELD 613@->PROVCOM
  GROUP 2
END

STRING 32
BEGIN
  KEY "VIA SEDE LEGALE"
  PROMPT 41 17 ""
  FIELD 116@->INDRES
  MESSAGE COPY,35
  FLAGS "H"
  GROUP 2
END

STRING 33
BEGIN
  KEY "NUM.CIV"
  PROMPT 93 4 ""
  FLAGS "H"
  FIELD 116@->CIVRES
  MESSAGE APPEND,35
END

STRINGA 34
BEGIN
  KEY "CAP SEDE LEGALE"
  PROMPT 121 17 ""
  FIELD 116@->CAPRES  
  GROUP 2  
END  
  
STRING 35
BEGIN
  KEY "VIA SEDE LEGALE"
  PROMPT 41 17 ""
  GROUP 2
END

STRING 36
BEGIN
  KEY "COMUNE DI RESIDENZA FISCALE"
  PROMPT 41 19 ""
  FIELD 813@->DENCOM
  GROUP 2
END

STRING 37
BEGIN
  KEY "PROV. RESIDENZA FISCALE"
  PROMPT 122 19 ""
  FIELD 813@->PROVCOM
  GROUP 2
END

STRINGA 37BIS
BEGIN
  KEY "FLAG RESIDENZA FISCALE"
  PROMPT 31 20 ""
  FIELD 116@->VARDF
  GROUP 2
END

STRING 38
BEGIN
  KEY "VIA RESIDENZA FISCALE"
  PROMPT 39 21 ""
  FIELD 116@->INDRF
  FLAGS "H"
  MESSAGE COPY,40
END

STRING 39
BEGIN
  KEY "NUM.CIV"
  PROMPT 93 4 ""
  FLAGS "H"
  FIELD 116@->CIVRF
  MESSAGE APPEND,40
END

STRING 40
BEGIN
  KEY "VIA RES FISCALE"
  PROMPT 41 21 ""
  GROUP 2
END

STRINGA 41
BEGIN
  KEY "CAP"
  PROMPT 122 21 ""
  FIELD 116@->CAPRF
  GROUP 2
END  

STRINGA 42
BEGIN
  KEY "DATA APP.BILANCIO gg-mm-aaa"
  PROMPT 31 23 ""
  PICTURE "## ^ ##  ^^###"
  FIELD 7->DATAAPPBIL
  GROUP 2
END

STRINGA 43
BEGIN
  KEY "Termine per APP.BILANCIO gg-mm-aaa"
  PROMPT 91 23 ""
  PICTURE "## ^ ##  ^^###"
  FIELD 7->DATATAPPBI
  GROUP 2
END

STRINGA 48
BEGIN    
  KEY "STATO"
  PROMPT 31 25 ""
  FIELD 7->STATOSOC
  GROUP 2
END

STRINGA 49
BEGIN    
  KEY "NAT.GIURIDICA"
  PROMPT 55 25 ""
  FIELD 7->NATGIU
  GROUP 2
END

LISTAA 50
BEGIN    
  KEY "SITUAZIONE"
  PROMPT 75 25 ""     
  FIELD 7->SITSOC  
  ITEM " | "
  ITEM "1|1" 
  ITEM "2|2"
  ITEM "3|3"
  ITEM "4| "
  ITEM "5|4"
  ITEM "6|5"          
  GROUP 2
END

STRINGA 51
BEGIN
  KEY "TELEFONO - PREF"
  PROMPT 102 25 ""
  FIELD 116@->PTELRF
  GROUP 2
END

STRINGA 52
BEGIN
  KEY "TELEFONO - NUMERO"
  PROMPT 113 25 ""
  FIELD 116@->TELRF   
  GROUP 2
END

NUMBER 53
BEGIN
  KEY "NUMERO ESTINTI"
  PROMPT 66 27 ""
END

STRINGA 54
BEGIN
  KEY "Dati RAPP. - COFI"
  PROMPT 25 29 ""  
  FIELD 216@->COFI
END

LISTA 55
BEGIN
  KEY "CODICE CARICA 1"
  PROMPT 86 29 ""
  ITEM " | "
  ITEM "1|X"
  ITEM "2|"
  ITEM "3|"
  ITEM "4|"
  ITEM "5|"
  ITEM "6|"
  FIELD 36->CARRAPP
END
LISTA 56
BEGIN
  KEY "CODICE CARICA 2"
  PROMPT 95 29 ""
  ITEM " | "  
  ITEM "1|"
  ITEM "2|X"
  ITEM "3|"
  ITEM "4|"
  ITEM "5|"
  ITEM "6|"
  FIELD 36->CARRAPP
END
LISTA 57
BEGIN
  KEY "CODICE CARICA 3"
  PROMPT 103 29 ""
  ITEM " |"  
  ITEM "1|"
  ITEM "2|"
  ITEM "3|X"
  ITEM "4|"
  ITEM "5|"
  ITEM "6|"
  FIELD 36->CARRAPP
END
LISTA 58
BEGIN
  KEY "CODICE CARICA 4"
  PROMPT 111 29 ""
  ITEM " |"  
  ITEM "1|"
  ITEM "2|"
  ITEM "3|"
  ITEM "4|X"
  ITEM "5|"
  ITEM "6|"
  FIELD 36->CARRAPP
END
LISTA 59
BEGIN
  KEY "CODICE CARICA 5"
  PROMPT 120 29 ""
  ITEM " |"  
  ITEM "1|"
  ITEM "2|"
  ITEM "3|"
  ITEM "4|"
  ITEM "5|X"
  ITEM "6|"
  FIELD 36->CARRAPP
END
LISTA 60
BEGIN
  KEY "CODICE CARICA 6"
  PROMPT 129 29 ""
  ITEM " |"    
  ITEM "1|"
  ITEM "2|"
  ITEM "3|"
  ITEM "4|"
  ITEM "5|"
  ITEM "6|X"
  FIELD 36->CARRAPP
END

STRINGA 61
BEGIN
  KEY "RAPP.COGNOME"
  PROMPT 25 31 ""
  FIELD 216@->RAGSOC[1,30]
END

STRINGA 62
BEGIN
  KEY "RAPP.NOME"
  PROMPT 82 31 ""         
  FIELD 216@->RAGSOC[31,50]  
END              

LISTA 63
BEGIN
  KEY "RAPP.SESSO"
  PROMPT 121 31 ""
  ITEM " | "  
  ITEM "M|X"
  ITEM "F|"
  FIELD 218@->SESSO
END

LISTA 64
BEGIN
  KEY "RAPP.SESSO"
  PROMPT 129 31 ""
  ITEM " | "  
  ITEM "M|"
  ITEM "F|X"
  FIELD 218@->SESSO  
END

STRINGA 65
BEGIN
  KEY "RAPP.DATANASC"
  PROMPT 25 33 ""
  PICTURE "## ^ ##  ^^###"
  FIELD 218@->DATANASC  
END

STRINGA 68
BEGIN
  KEY "COMUNE NA"
  PROMPT 46 33 ""
  FIELD 313@->DENCOM
END              

STRINGA 69
BEGIN
  KEY "PROV NA"
  PROMPT 121 33 ""
  FIELD 313@->PROVCOM  
END
  
STRINGA 70
BEGIN
  KEY "COMUNE RES"
  PROMPT 42 35 "" 
  FIELD 413@->DENCOM  
END

STRINGA 71
BEGIN
  KEY "PROV RES"
  PROMPT 101 35 ""
  FIELD 413@->PROVCOM  
END       

STRINGA 72
BEGIN
  KEY "CAP RES"  
  PROMPT 121 35 ""  
  FIELD 216@->CAPRF  
  FIELD 216@->CAPRES
END       

STRINGA 73
BEGIN
  KEY "IND RES"   
  PROMPT 42 37 ""  
  FIELD 216@->INDRF   
  FIELD 216@->INDRES
  FLAGS "H"
  MESSAGE COPY,75
END       

STRING 74
BEGIN
  KEY "NUM.CIV"
  PROMPT 93 4 ""
  FLAGS "H"
  FIELD 216@->CIVRF 
  FIELD 216@->CIVRES  
  MESSAGE APPEND,75
END

STRINGA 75
BEGIN
  KEY "IND RES"   
  PROMPT 42 37 ""  
END

STRINGA 76
BEGIN
 KEY "TELEFONO PREFISSO"
 PROMPT 101 37 ""  
 FIELD 216@->PTELRF
END

STRINGA 77
BEGIN
 KEY "TELEFONO NUMERO"
 PROMPT 113 37 ""
 FIELD 216@->TELRF   
END

STRINGA 78
BEGIN
  KEY "LUOGO CONSERVAZIONE S.C. - NOME"
  PROMPT 25 38 ""
  FIELD 316@->RAGSOC
END

STRINGA 79
BEGIN
  KEY "LUOGO CONSERVAZIONE S.C. - COM"
  PROMPT 25 39 ""     
  FIELD 513@->DENCOM 
  FIELD 713@->DENCOM  
END

STRINGA 80
BEGIN
  KEY "LUOGO CONSERVAZIONE S.C. - PROV"
  PROMPT 92 39 ""
  FIELD 513@->PROVCOM
  FIELD 713@->PROVCOM
END
  
STRINGA 81
BEGIN
  KEY "LUOGO CONSERVAZIONE S.C. - VIA"
  PROMPT 25 40 ""
  FIELD 10->INDCS
  FIELD 316@->INDRF 
  FIELD 316@->INDRES  
END

STRINGA 82
BEGIN
  KEY "LUOGO CONSERVAZIONE S.C. - CIV"
  PROMPT 82 40 ""
  FIELD 10->CIVCS
  FIELD 316@->CIVRF 
  FIELD 316@->CIVRES  
END

STRINGA 83
BEGIN
  KEY "LUOGO CONSERVAZIONE S.C. - CAP"
  PROMPT 112 40 ""
  FIELD 10->CAPCS
  FIELD 316@->CAPRF 
  FIELD 316@->CAPRES  
END

END

SECTION FOOTER FIRST 4

STRINGA 82
BEGIN
  KEY "AMMIN. 1 NOME"
  PROMPT 24 1 ""
END

STRINGA 83
BEGIN
  KEY "AMMIN. 1 SESSO"
  PROMPT 54 1 ""
END
  
STRINGA 84
BEGIN
  KEY "AMMIN. 1 COMUNENA"
  PROMPT 58 1 ""
END

STRINGA 85
BEGIN
  KEY "AMMIN. 1 PROVNA"
  PROMPT 83 1 ""
END
  
STRINGA 86
BEGIN
  KEY "AMMIN. 1 DATANA"
  PROMPT 89 1 ""
END

STRINGA 87
BEGIN
  KEY "AMMIN. 1 CODFIS"
  PROMPT 102 1 ""
END

STRINGA 88
BEGIN
  KEY "AMMIN. 1 QUALIFICA"
  PROMPT 130 1 ""
END
  
END

END

