Have to do a little research and get a little creative:
Completely untested, since I know nothing about AttIn.
- (defun c:UberGatte (/ TextFile) (and (or bns_attin (load (findfile "attout.lsp") nil)) (setq TextFile (getfiled "Select a Text file for global attributes edit" "C:\\Documents and Settings\\rxbeeto0\\Temp\" "txt;*" 8 ) ;_ getfiled ) ;_ setq (foreach Ln (layoutlist) (setvar "CTAB" Ln) (if (equal 4 (logand 4 (getvar "cmdactive"))) (bns_attin TextFile nil) ;a script is running so no interactive placement (bns_attin TextFile T) ;Allow interactive placement ) ;_ if ) ;_ foreach ) ;_ and (princ)) ;_ defun
I hope you don't mind, I did a little reworking on your code. BTW, you can use getfiled when only needing to select 1 file and avoid relying on dos_lib. |