!This file is part of VEL_demo, copyright David Keyes, 2007. ! !This source file is free software: you can redistribute it and/or modify !it under the terms of the GNU General Public License as published by !the Free Software Foundation, either version 3 of the License, or !(at your option) any later version. ! !This code is distributed in the hope that it will be useful, !but WITHOUT ANY WARRANTY; without even the implied warranty of !MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the !GNU General Public License for more details. ! !For terms of the GNU General Public license see . GLOBAL MODULE split_str( STRING input*132; STRING split_chr*1; VAR STRING left*132; VAR STRING right*132); INT n; BEGINMODULE n:=finds(input, split_chr); IF n <> 0 THEN left:=substr(input, 1, n-1); right:=substr(input, n+1); ELSE left:=input; right:=" "; ENDIF; ENDMODULE