ACAD 2 ICAD Lisp Question

Topics relating to AutoLisp and SDS.

Moderators: CMS Inc, avaernes

Post Reply
jmkarlo
Newbie
Posts: 2
Joined: Wed Mar 17, 2010 3:11 pm

ACAD 2 ICAD Lisp Question

Post by jmkarlo » Fri Mar 19, 2010 3:16 pm

I am evaluating iCAD from after 20 years of ought-to-CAD. I have a few questions like;

1. What folder should I put my Lisp files in. I have them in the support folder right now but iCAD doesn't seem to find them. iCAD has found my menus, and templates.

2. Does iCAD have the equvilant of an ACAD.PGP file? Where is it and can I edit it like an ACAD.PGP file? I have a few days left of my evaluation copy of the program and I want to make sure this will work before I commit.

I'm sure I'll have a few more questions later.

Jerry K.
jmkarlo
Newbie
Posts: 2
Joined: Wed Mar 17, 2010 3:11 pm

Location of LSP files?

Post by jmkarlo » Fri Mar 19, 2010 3:24 pm

Funny, I just searched my entire hard drive of this new computer that I have iCAD on and not one *.lsp file was found. (my Lisp files are located on a newtwork drive.) Somebody please fill me in.
JCAMPOS

Post by JCAMPOS » Mon Mar 22, 2010 4:06 am

jmkarlo,

To answer your questions:

1. You can put your LISP files anywhere. However, I suggest you to put them outside the program's installation folder. To load lsp files in IntelliCAD, use the command APPLOAD. This command lets you select the files with a file browser. To automatically load your LISP files use the icad.lsp: Open notepad, type the following:
(load "[MyLispFileWithCompletePath].lsp"), for example:

Code: Select all

(load "C:\\MyRoutines\\Geometry\\Rectangle.lsp")
Then, save the file and put it inside the program's installation folder, the same where icad.exe is. Then, the next time you open IntelliCAD, your LISP files will be automatically loaded.

2. Yes, IntelliCAD works also with PGP files, however there should be no need to edit them in the PGP files as IntelliCAD has an editor to do it. In the "Customize" dialog box (Tools->Customize...), there is a tab named "Aliases". Go to this tab to edit your command aliases. If you need, you will be able also to export/import the aliases to/from PGP/ICA files.

Thanks,
JCAMPOS
jamesclane
Contributor
Posts: 13
Joined: Thu Mar 02, 2006 12:01 am
Location: Greenville, SC, USA
Contact:

Post by jamesclane » Mon Jan 10, 2011 2:53 pm

I agree with JCAMPOS on putting them in an alternate directory (folder, sorry old habits die hard).

Given the lack of a "support" path a la autocad, I choose to modify my windows path since CAD is a primary function of this computer.

start>control panel>system (system>advanced system settings in vista/win7)>environment variables>path.

Worked like a charm.
JCAMPOS

Post by JCAMPOS » Tue Jan 11, 2011 8:54 am

jamesclane,

To force CMS IntelliCAD to "see" and load an icad.lsp that resides on a different directory than the program's installation folder, you have a more direct and cleaner solution. Try the following:

1. Right-click on IntelliCAD's desktop shortcut and select "Properties" in the context menu;
2. Enter your alternate directory in the "Start in:" textbox.
3. Click the "Apply" button and there you go! After this, everytime you run IntelliCAD it will start on that directory loading the icad.lsp (if saved on that directory).

Hope it helps!

Regards,
JCAMPOS
jamesclane
Contributor
Posts: 13
Joined: Thu Mar 02, 2006 12:01 am
Location: Greenville, SC, USA
Contact:

Post by jamesclane » Sat Jan 15, 2011 6:16 pm

JCAMPOS

Thanks for your input. I may have misunderstood the original thread questions.

As I have been migrating our company from Autocad to Intellicad I have been tweaking a number of lisp routines that are the core or our design function. Historically, I have always kept the lisp files in a separate directory from the main program install directory to make updating other users easier and less hazardous. Autocad has powerful "support file" path support. Intellicad's internal path support is a little less granular. So I have been trying out alternative approaches.

Presently, I do keep the modified icad.lsp file in the program install directory but was trying to keep the "working" lisp files grouped in separate directory.

That being said, I put the icad.lsp file in the same directory as the "working" lisp files and tried the method you suggested. Worked like a charm and I like that the "path" is program specific.

Great tip, thanks.



UPDATE:
Ran into one minor snag. When I double click on a "dwg" file to open it, or open it with the context menu, intellicad uses the programs default paths.
Accuright
Valued Contributor
Posts: 47
Joined: Thu Jul 26, 2012 2:19 pm

Post by Accuright » Thu Nov 15, 2012 1:22 pm

Discovered this today working with some lisp routines for iCAD.

The icad.lsp file is loaded every time IntelliCAD is launched. This works dandy but if you open a new or existing drawing after IntelliCAD has launched, then your lisp routines will not be loaded.

icaddoc.lsp is another LISP file that IntelliCAD automatically loads into each drawing environment. This file does not exist by default, but I created it and tested this functionality. You do not need to set your files in APPLOAD if you use this lsp file.
Userlevel6
Valued Contributor
Posts: 31
Joined: Tue Sep 18, 2012 11:44 am

support paths

Post by Userlevel6 » Wed Jun 05, 2013 12:48 pm

Frankly this was one of the first "what do I do now" issues I had in migrating to ICAD after many, many years of ACAD use.

If you ever had the experience of configuring ACAD support paths, you'll find the concepts and "gotchas" to be about the same.

Keep your LISP programs in their own folder, same for blocks .dwg files, bitmap .BMP files for menu toolbar support.

For simplicity, add calls to your supporting folders to the "Support Paths - Help" tree of your Paths/Files tab in ICAD CONFIG, if you don't see a more appropriate location. Using different branches of the paths config tree may change the order in which support files are loaded, but in the end your files should work as long as they are referenced here somewhere.

Use ICAD.LSP for initializing the program.
Create/Use ICADDOC.LSP for initializing LISP routines.

Keep backups of your support files.
Post Reply