Editing Programmazione

Jump to navigation Jump to search

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.

Latest revision Your text
Line 63: Line 63:
 
<pre>LOCAL Integer MYOK
 
<pre>LOCAL Integer MYOK
 
CALL VALID("TRT","SPEITM", nomap, MYOK) From VALMSKSUB         
 
CALL VALID("TRT","SPEITM", nomap, MYOK) From VALMSKSUB         
 +
</pre>
 +
#per recuperare nomi campi di un blocco (riporto codice per MEMO):<br /> 
 +
<pre>
 +
######################################################################################
 +
# SU APERTURA FINESTRA. una sola volta
 +
# Utilizzare abbreviazioni per tabelle NON STANDARD. cambiare AMZ in YMZ!
 +
$OUVRE
 +
  #If GUSER='IT102' Dbgaff : Endif
 +
 +
   
 +
   
 +
  # Apro le tabelle utilizzate
 +
  If !clalev ([F:YII])  : Local File YITMINF [YII] :  Endif
 +
  If !clalev ([F:YII_]) : Local File YITMINF [YII_] :  Endif
 +
  If !clalev ([F:YIIT]) : Local File YITMINF [YIIT] :  Endif # riferimento tabella YITMINF x controllare unicità YCODARTCLI
 +
  If !clalev ([F:YITM]) : Local File ITMMASTER [YITM] :  Endif
 +
 +
 
 +
 +
  #
 +
  #Gestione di Blocchi di campi.
 +
  #Registrazione utente/data/ora inserimento/modifica/cancellazione su blocco di controlli
 +
  #
 +
 +
  #
 +
  #Dichiarazione array con nomi campi contenuti nei riquadri da gestire
 +
  #Local Integer MAXCAMPIBLOCK : MAXCAMPIBLOCK=13
 +
  #Local Char BLKBUFFER(30)(MAXCAMPIBLOCK)
 +
 +
  #Local Integer NRBLKYIT1
 +
  #Local Integer C
 +
  #Local Char TEST(30)
 +
  # Recuperare il numero di blocchi da gestire e loro dimensioni
 +
  #If !clalev ([F:YMZ]) : Local File AMSKZON [YMZ] : Else Filter [F:YMZ] :ENDIF
 +
  #NRBLKYIT1 = func GETNRBLOC('YIT1')
 +
  #Local Integer VIDYIT1(NRBLKYIT1)
 +
  #Local Char BLK01(30)(NRBLKYIT1)
 +
 
 +
  #Local Char BLK1(30)(MAXCAMPIBLOCK)
 +
  #Local Char BLK2(30)(MAXCAMPIBLOCK)
 +
  #Local Char BLK3(30)(MAXCAMPIBLOCK)
 +
  #Local Char BLK4(30)(MAXCAMPIBLOCK)
 +
  #Local Char BLK5(30)(MAXCAMPIBLOCK)
 +
  #Local Char BLK6(30)(MAXCAMPIBLOCK)
 +
  #Local Char BLK7(30)(MAXCAMPIBLOCK)
 +
  #Local Char BLK8(30)(MAXCAMPIBLOCK)
 +
  #Local Char BLK9(30)(MAXCAMPIBLOCK)
 +
  #Local Char BLK10(30)(MAXCAMPIBLOCK)
 +
 
 +
  # partire dal code by AZ
 +
  #For C=1 To NRBLKYIT1
 +
  #  Call GETBLOCKNAMES('YIT1', C, BLKBUFFER) From YSS02SPEITM   
 +
  #  For K=0 To MAXCAMPIBLOCK-1
 +
  #      #Assign 'BLK'+num$(I)+'('+num$(K)+')' With evalue('BLKBUFFER('+num$(K)+')')
 +
  #      Assign 'BLK'+num$(C)+'('+num$(K)+')' With evalue('BLKBUFFER')
 +
  #  Next K
 +
  #Next C
 +
# fine inizializzazione array con nomi campi x blocco
 +
# code by AZ
 +
 +
#Local Char A(30)
 +
#MAXB = func SPEITM.GETNRBLOC('YIT1')
 +
#Local Char BLK1(30)(10)
 +
#Local Char BLK2(30)(10)
 +
#Local Char BLK3(30)(10)
 +
#Local Char BLK4(30)(10)
 +
#Local Char BLK5(30)(10)
 +
#Local Char BLK6(30)(10)
 +
#Local Char BLK7(30)(10)
 +
#Local Char BLK8(30)(10)
 +
#Local Char BLK9(30)(10)
 +
#Local Char BLK10(30)(10)
 +
#Dbgaff
 +
#For I=1 To MAXB
 +
#    A='BLK'+num$(I)
 +
#    #Call GETBLOCKNAMES('YIT1', I, evalue(A)) From SPEITM   
 +
#    Call GETBLOCKNAMES('YIT1', I, BLK10) From SPEITM   
 +
#    For K=0 To 9
 +
#        Assign 'BLK'+num$(I)+'('+num$(K)+')' With evalue('BLK10('+num$(K)+')')
 +
#    Next
 +
#Next
 +
#Infbox BLK1(0)-BLK1(1)-BLK1(2)-'#'-BLK2
 +
 +
#End code AZ
 +
 +
 +
  #Filter [F:YMZ]
 +
  #Filter [F:YMZ] Where [F:AMZ]CODMSK='YIT2' Order By [F:AMZ]NUMBLOC Desc
 +
  #Local Integer VIDYIT2(func GETNRBLOC('YIT2'))
 +
 
 +
  #Filter [F:YMZ]
 +
  #Filter [F:YMZ] Where [F:AMZ]CODMSK='YIT3' Order By [F:AMZ]NUMBLOC Desc
 +
  #Local Integer VIDYIT3(func GETNRBLOC('YIT3'))
 +
 +
 +
  # Define variabili flag per registare se vengono fatti cambiamenti ai campi.
 +
  # IN registrazione verrà salvato il timestamp di salvataggio
 +
Return
 +
 
</pre>
 
</pre>

Please note that all contributions to SageDev KB may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see SageDev KB:Copyrights for details). Do not submit copyrighted work without permission!

Cancel Editing help (opens in new window)