'You can use ENVIRON$ to find out a lot of things, like the PC username: CLS : s = 1 COLOR 11: LOCATE 2, 27: PRINT "DOS Environment Variables": PRINT DO WHILE ENVIRON$(s) <> "" COLOR 14: PRINT s; ENVIRON$(s) s = s + 1 IF s MOD 20 = 0 THEN LOCATE 24, 25: PRINT "Press Any Key to continue!"; DO: SLEEP: LOOP UNTIL INKEY$ <> "" CLS COLOR 11: LOCATE 2, 27: PRINT "DOS Environment Variables": PRINT END IF LOOP COLOR 11: LOCATE 24, 2: PRINT "End of list! Press Any Key!" DO: SLEEP: LOOP UNTIL INKEY$ <> "" 'You can use the value string names listed to pick which setting to return. CLS Prompt$ = ENVIRON$("PROMPT") User$ = ENVIRON$("USERNAME") Puter$ = ENVIRON$("COMPUTERNAME") OpSys$ = ENVIRON$("OS") Blaster$ = ENVIRON$("BLASTER") COLOR 14: LOCATE 15, 25: PRINT "DOS Prompt = "; Prompt$ LOCATE 16, 25: PRINT " User Name = "; User$ LOCATE 17, 25: PRINT " Computer = "; Puter$ LOCATE 18, 25: PRINT "OS Version = "; OpSys$ LOCATE 19, 25: PRINT " Blaster = "; Blaster$ 'I don't know what VISTA or 7 will return, but Win 9x return little. 'Ted
|