I use the following lisp to open project folders straight from a pulldown. My problem is handling comma's in the project name. The lisp asks for the job number, searches the Job_List.txt file for the full project folder name, then opens the folder thru explorer. It works for the 200659 project, but not the 200768 project because of the comma in the folder name, I'm assuming. Any thoughts?
Truncated contents of "Job_List.txt"
200659 Mini-Mart (7601 S. State Street)
200768 Merlin Mufflers & 3-Unit Retail (Mokena, IL)
Open_Job_Folder.lsp
(defun c:Open_Job_Folder (/ output file search nl tc rf tl)
(IF jobnum (SETQ search jobnum)(setq search (getstring t "\nJob Number: ")))
(setq tc "No")
(setq rf (open "Z:/Projects/Job_List.txt" "r"))
(while (setq nl (read-line rf))
(if (= tc "No")
(setq tl (strcase nl)
search (strcase search))
(setq tl nl))
(if (wcmatch tl (strcat "*" search "*"))
(setq output (cons nl output))))
(close rf)
(foreach n output (setq job n))
(setq year (substr job 1 4))
(setq job (strcat "Z:\\projects\\" year " projects\\" job "\\"))
(startapp "explorer" job)
(setq jobnum nil
job nil
year nil)
)