// screendev.js - open four programming screen windows with SecureCRT // Andrew Ho (andrew@zeuscat.com) // // Usage: wscript screendev.js // // Before using this script, you will need to edit the places marked // with "FIXME" (no quotes) below to add a real SecureCRT session name. // You may also need to tweak the argPositionsWorkDev[] values. // // See http://www.zeuscat.com/andrew/software/desktop_hacks/#scripted-windows // for some background information about how I use this script. var programSecureCRT = '"C:/Program Files/SecureCRT/SecureCRT.EXE"'; var argSessionsWorkDev = new Array( '"Screen Sessions/FIXME (screen 1)"', '"Screen Sessions/FIXME (screen 2)"', '"Screen Sessions/FIXME (screen 3)"', '"Screen Sessions/FIXME (screen 4)"' ); // These window positions are worked out for 4 windows on a 1600x1200 // screen, each window 80x40, using Courier New 12pt. You may need to // adjust them for a different window or screen size. var argPositionsWorkDev = new Array('0 0', '770 0', '70 373', '630 373'); var shell = new ActiveXObject("WScript.shell"); for(var i = 0; i < argSessionsWorkDev.length; i++) { runSecureCRT(shell, argPositionsWorkDev[i], argSessionsWorkDev[i]); } function runSecureCRT(shell, position, session) { shell.Run(programSecureCRT + ' /POS ' + position + ' /S ' + session); WScript.sleep(500); }