John; One way to deal with this is to call a process from the derived slot of the dict that parses out the @PARAM variable and calls the subroutine, then to get the dict to work at TCL in the <F6> Addit, <F6> OE Dict derived field put what you need to call the subr from the dictionary. Unfortunately, this will "hard-code" it for the database - if you need to run it on multiple databases.
Eg: Derived field: (P("P.CALLSYSS9075.1,VIA,":SHIP_VIA:")) <F6>,<F6>: EXTRACT(@RECORD,10,0,0);SUBR("SYSS9075.1",'VIA',@1) And P.CALLSYSS9075.1 looks something like: LOCAL DATAVAL, SHIP.TYPE, SHIP.VIA DATAVAL = "" SHIP.TYPE = FIELD(@PARAM,',',1) SHIP.VIA = FIELD(@PARAM,',',2) CALL SYSS9075.1(DATAVAL,SHIP.TYPE,SHIP.VIA) @VALUE = DATAVAL @RTN.FLAG = 0 I thought I had figured out another way to do this but I can't quite recall what it was.... Hth Colin Alfke Calgary, Canada -----Original Message----- From: Israel, John R. I need help building a SB Dict that calls a User Subroutine with several arguments. This needs to work from both within SB screens and from TCL. Originally, I have a derived field defined as: (B("SYSS9075.1,'VIA',SHIP_VIA")) where SYSS9075.1 had three arguments, 'VIA' was hard coded and SHIP_VIA was whatever value was in that field (in this case, field 10). This worked fine from TCL, but SB was blowing up with an error about incorrect number of arguments (and would likely not have a clue what SHIP_VIA meant). I then tried: (B("SYSS9075.1,'VIA','10'")) where SYSS9075.1 had no arguments, and extract the info from PARAMS. This works from SB screens, but I am clueless how to pass the arguments in the DICT used at TCL. Any Gurus out there have a suggestion or two? John Israel _______________________________________________ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users