blog.CadKicks

Behind the scenes look at whats happening here at CadKicks

About the author

Author Name is someone.
E-mail me Send mail

Recent comments

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2008

Quick little routine to Convert a Directory of LSP to FAS

Quick little routine to Convert a Directory of LSP to FAS. I found this Online and decided to modify it for MANUALLY setting the paths.

 

; ConvToFAS = Convert Lsp To Fas
; Cool little APP to convert a DIR of LSP to FAS
; Homepage : Adesu <Ade Suharna> http://www.yuasa-battery.co.id
; You MUST LOAD VLIDE FIRST

; Edited by Jose Guia - SET the Source and Dest manually instead of prompting
; http://www.cadkicks.com

(defun c:ConvToFAS (/ lsp fas lst)
(vl-load-com)
  (setq lsp "C:/legacy_source_lisp_files/Compile/");;Source Folder
  (setq fas "C:/legacy_source_lisp_files/Compile/FAS/");;DEST Folder
  (setq lst (vl-directory-files lsp "*.lsp" 1))
    (if
      lst
      (progn
      (foreach x lst
      (vlisp-compile
      'st
      (strcat lsp x)
      (strcat fas (substr x 1 ( - (strlen x) 4)) ".fas")
      )
      ) ; foreach
      ) ; progn
      (alert "No FILES")
    ) ; if
  (princ)
) ; defun

 

 


Categories: CAD | LSP
Posted by Admin on Monday, March 03, 2008 7:58 AM
Permalink | Comments (0) | Post RSSRSS comment feed