From the course: Learning AutoLISP & Visual LISP

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Function: strcat

Function: strcat - AutoCAD Tutorial

From the course: Learning AutoLISP & Visual LISP

Start my 1-month free trial

Function: strcat

- [Instructor] Another common string LISP function is where we're able to combine one string with another string. We do this with the LISP function named string cat where we combine the two strings together. Let's take a look at this. If we string together or combine two strings such as "Current layer is," that's our first string and then we get the current layer from the variable CLAYER. Let's go ahead and just print that out to the command line. We use three different LISP functions in one line of our text. One gets the variable, CLAYER. It combines it using string cat with "Current layer is" and then it writes that entire line to the command line. We can see at the command line current layer is zero. String cat is going to be used quite a bit in other samples and example codes in later chapters.

Contents