Author Topic: Loading and reading SHX files for linetypes.  (Read 4691 times)

0 Members and 1 Guest are viewing this topic.


  • Newt
  • Posts: 132
Loading and reading SHX files for linetypes.
« on: December 31, 2012, 02:32:15 PM »
This is really more complicated than the subject line, but what I seem to be seeing is some limit to how many SHX files AutoCAD will automatically search for.
First things first - we have client supplied DWT files with a number of complex linetypes. They supply SHX files but no LIN files.
I found some lsp and vlx routines which can write a lin file from linetypes in the files. All of these warn of issues with reading the shapes in the SHX files with the results being almost correct. Here is what I have found.
The exported lin file lists 3 SHX files. One of the routines - from - works better than the others. It correctly names the shapes in the first SHX file - ltypeshp.shx. When it comes to the second and third SHX file, it uses the name of the last shape it found used in ltypeshp.shx, instead of the correct shape name.
I have placed all of the shx files in the same folder which is also the first folder in my support search paths. I also manually loaded all of the shx files using the load command. But still, only the shapes in ltypeshp.shx are read by the routine.
I also tried using the design center to create a file with only the complex linetypes using shapes from one of the other two files. In that case, the routine placed  the text {shapeN}where the shape name should have been. From this, I could count down into the shape names, in the shape file, to determine which name is at which index (N) and with that, manually correct the LIN file.
So the real question is, has anyone else tried using one of these tools to write an LIN file from linetypes and have you found a way to get it to list all shape names?