[Search tip detail and code files using keywords, tip number, author name, etc ]
 
    For tip to function correctly, you must ensure that the downloaded file name matches the file name
    displayed in the Rename File To field. Please rename downloaded files when necessary.
Insert Blocks
Tip# ALSPSOL105 By Tony Hotchkiss On 01-Jan-2005
4
Rated By 1 users Downloaded : 599
Categories : Attributed Blocks, Blocks
Software type : AutoCAD
Rename File To : insblk2.dcl, insblk2.lsp
Routine by Tony Hotchkiss inserts blocks with geologic sample attributes (insblk2.lsp, insblk.dcl)

Bob Stirling from Whitehorse in Canada's Yukon Territory works with geographical information systems (GIS) for rock and soil geochemistry. He uses assay information in the form of spreadsheets that contain sample data with blocks representing a variety of rock, soil or silt (or other conditions) and attributes that describe the assay location, identifier and any number of other attributes, depending on the block symbol. Bob requested a routine that would plot the assay data by inserting the blocks and displaying the attribute values from the spreadsheet.

This AutoLISP Solution is a return to a program that first appeared in Cadalyst some time ago, and has been modified considerably to become INS-BLK2.LSP. The new routine not only inserts blocks at designated locations, but also adds any number of attributes contained in each of the block definitions. Attribute values are defined in the spreadsheet data. The number of attributes for each block is defined by the block itself, and the order of the attributes is predefined when the attribute definitions were selected to form the block. The spreadsheet data does not specifically name any attribute tags, but only contains the attribute values, together with the block names and their intended x (east), y (north), and z (elevation) insertion points.

Get the Code
Download the INS-BLK2.LSP and INS-BLK2.DCL files from the Get the Code area at Cadalyst.com and save them in AutoCAD's Support directory. Use the Appload facility by selecting Tools / Load Application. Then select the INS-BLK2.LSP program from where you stored the downloaded files.







 

 

Average Rating:
4


User comments


Log In