T24 Notes Programming
T24 Notes Programming
SETVAR
-1 end of array reached
-2 array delimited by FM
-3 array delimited by VM
-4 array delimited by SM
SYSTEM(43) – to identify which port has lock in case of readu locked
Lock is released :
WRITE, WRITEV, MATWRITE
RELEASE, DELETE
SHOW ITEM LOCKS
TRANSSTART
TRANSEND
FIND
SUBSTRINGS
Output
ABC
BB
B1 B2
Locate – position of item for multiple items 1,2 position of vm items
T24 API
Open for company specific FBNK, FCO2 etc not portable
CALL OPF(Name,Path)
OPF – File control checked for classification if not found in file type buffer
Jbase open performed to get file path if not found in file open buffer
Session
Classic – Always open for user , cache remains in T24 server , usually connection by telnet
Browser – TSS session cache(TCSERVER) in web server of browser , no guaranty info will be retained
if req from other server.
F.READ
Y.CURRENCY == R.ACC(8) or you should use field name as position can change with release
INSERT FILES
Common
I_COMMON I_EQUATE
Application specific
I_F.CUSTOMER
I_F.ACCOUNT
JBCLIB_DEV path to store routine objects
JBCGLOBALDIR Global path for having jLibDefinition
jLibDefinition Used by jbase to auto create library if full
jshow -c gives details of actual library file and path where code is catalogued
jshow -a give actual content of library file
Insert vs include
JBCOBJECTLIST : Contains search path for all objects
F.READU
EB.TRANS(‘START’,’’)
EB.TRANS(‘END’,’’)
EB.ABORT triggered when error
EB.READLIST :
Use mostly for static table SECTOR , CATEGORY , don’t use for ACCOUNT
OPENSEQ
Writeseq
CLOSESEQ
Example
READSEQ
Open sequential file with path
Sequential file is open , only one type of operation can be done read/write.
Code Review
Eb.compile is used for catalog and compile.
The negative ranking is good sign/ positive ranking means lot to improve.
Size/Number of lines
If the line of code is greater than 600 the +10 ranking.
GoSUB
Break up long program into smaller ones. Use CALL statement to bring
Top down approach, -10 for GOSUB component
Paragraph depth
If paragraph is more than 100 lines, than weightage 5 is given
Nesting
The max. no. of nesting statement is 3, if more than 3 than weightage is 50
Improve – by using CASE.
Nesting Depth
Maximum number of lines within an IF… END statement is 40 anything over
will affect the ranking by 5. Improve – using GOSUB within nested IF’s.
Comment
For each line of comment the weightage is -1.
GOTO
use of GOTO never recommended. Weightage is 100.
Temenos allows GOTO with locked clause.
GOTO never returns the point of origin unlike GOSUB. Improve – paragraph