cadalyst
Management

The Return of Hot Tip Harry (Hot Tip Harry AutoCAD Tutorial)

31 Dec, 2007 By: Bill Kramer

Harry rejoins the magazine pages with a routine that searches his Get the Code! database.


GET THE CODE
Download code for this and all articles. Look for JAN08.EXE or JAN08.ZIP in Get the Code. Downloads are free and are provided "as is" without warranty or support.
Tips are tested using AutoCAD 2008, unless otherwise noted. By submitting code to Cadalyst, you grant Cadalyst the right to print and distribute your code in print, digitally and by other means. Cadalyst and individual authors retain all rights to the code, and it is not to be used for commercial purposes.
Important note: Be sure your submission contains all elements required for it to run independently in AutoCAD. Tips that are missing functions or other necessary elements will not be considered.
Join the Hot Tip Harry Hot Code Contest
Calling all tip writers! The Hot Tip Harry Hot Code Contest is under way for 2008.
Share your hot tips and tricks and you could win an official Cadalyst t-shirt, $100 monthly cash prize, and a chance to win a trip to Autodesk University 2008 in Las Vegas!
E-mail those tips and tricks to harry@cadalyst.com.
For More AutoCAD Tips More Often: Check out Cadalyst's free Tips & Tools Weekly e-newsletter. View the archives and subscribe today!
Harry's Code Class Free E-Newsletter: Learn from the master himself. "Hot Tip Harry" author Bill Kramer offers monthly lessons in customization programming for AutoCAD. View the archives and subscribe today!
This month, in response to reader demand and after running as a Cadalyst.com exclusive for the past three years, “Hot Tip Harry” returns to the magazine. When Harry got the news that he was back in the ink to get his message out, he was elated. To commemorate that fact and to assist everyone in getting the most from this extensive library of tips and tricks, this month Harry presents his own tool for all to use when seeking an elusive tip

Searching through the Get the Code! archive for a specific tip can be daunting, so this month Harry offers some assistance. Using this routine while in AutoCAD, users can search by keywords, such as layer and color, to help locate a tip.

The Get the Code! archive includes more than 1,500 tips from more than 800 authors. Among these tips you’ll find more than 1,300 LISP programs and 200 or so dialog box files. You can use each tip as is in most cases or as a starting point or reference to develop your own AutoCAD customization solution to address a similar challenge. This amazing archive also shows how AutoCAD has evolved during the past 15 years; some of these functions are just as useful for AutoCAD 2008 as they were way back when.

Tip 2264: Get the Code! Search
Harry’s new routine, Get the Code! Search, was inspired by a loyal reader, Mike Stachulak, who has compiled a list of all “Hot Tip Harry” tips (including tip names and descriptions) from 1992 through 2007 into a single, searchable Microsoft Word file. Harry awards Stachulak this month’s Top Tip honor — and a $100 prize — for sharing this invaluable resource.

You can download Stachulak’s list (getthecode.doc) as part of the January 2008 Get the Code! files available on the Cadalyst Web site (www.cadalyst.com/code). The Get the Code! archive is organized by month and year to correspond with each “Hot Tip Harry” column, dating back to 1992. (Cadalyst introduced “Hot Tip Harry” in the late 1980s. According to Harry’s legend and lore, pre-1992 code was destroyed by a virus on an old backup disk. Apparently, someone sneezed on it. But that’s just legend; no one knows the real truth to the matter. Except maybe Harry, and he’s not talking.)

Also included in this month’s batch of code is a Visual LISP program (getthecode.lsp) and 16 text files that contain the same basic information you can find online for “Hot Tip Harry” tips, including tip publication dates, titles, and descriptions. Copy these files to the default work folder and load the LISP code. The LISP program will run in versions of AutoCAD that contain Visual LISP. When you use the tool inside AutoCAD, it will help you find which month a particular tip or tool appeared. Next, type HTH at the AutoCAD command prompt to activate this simple but useful indexing tool. You will be asked to locate the file hth1992.txt if it is not found automatically. When located, the program reads the hth*.txt files and is ready for you to type in a search keyword. A dialog box pops up for that purpose. After a search is performed, the results are displayed in the dialog box. Pick the tip of interest in the list to see more details and note the month and year of publication.

You’ll find the corresponding file on the Get the Code! site at www.cadalyst.com/code. Navigate to the year and month where your desired tip resides and download the ZIP or EXE file for that month. The trick is to figure out which tip in the download is the one you want. In some cases, it’s obvious; in others, you’ll have to work at it a bit. Generally, each download contains roughly 6–12 tips, so it shouldn’t take too long to locate the specific one of interest.

Get the Code! Search isn’t fully automated, as you can see. And of course, you can always try the Search function built into the Get the Code! site. However, this routine will help those users who like the idea of launching the search from AutoCAD, and in many cases could produce better results. By searching offline for specific tips, you can determine in advance if there’s anything that may serve your purpose before visiting the Web site.

In the meantime, the library needs reader contributions to continue its growth, and Harry encourages submissions whether you’re a veteran tipster or a first-timer. Before sending your tip, check Get the Code! to be sure Harry doesn’t already have a similar routine, then e-mail Harry at harry@cadalyst.com. If we publish your tip, you’ll be eligible to win some great prizes, including T-shirts, cash prizes, and a trip to Autodesk University 2008 in Las Vegas.

Until next month, keep on programmin’!


About the Author: Bill Kramer


More News and Resources from Cadalyst Partners

For Mold Designers! Cadalyst has an area of our site focused on technologies and resources specific to the mold design professional. Sponsored by Siemens NX.  Visit the Equipped Mold Designer here!


For Architects! Cadalyst has an area of our site focused on technologies and resources specific to the building design professional. Sponsored by HP.  Visit the Equipped Architect here!