* Windows GetCommandLineA sample code; * Richard A. DeVenezia; * http://www.devenezia.com; filename SASCBTBL catalog 'WORK.WINAPI.GETCMDLN.SOURCE'; data _null_; file SASCBTBL; input ; put _infile_; cards4; routine GetCommandLineA module = kernel32 minarg = 0 maxarg = 0 stackpop = called returns = long ; ;;;; data _null_; addr = modulen ('GetCommandLineA'); if addr > 0 then do; cmdline = peekc (addr,200); z = index (cmdline, '0000'x); cmdline = translate (substr (cmdline,1,z), ' ', '00'x); put cmdline=; end; run;