Display full version of the post: Getpat

smiddendorf
21.02.2017, 23:37

The fabulous GETPAT lisp has stopped working on all of my computers.  It gives me a "Bad Argument" error message when I attempt to use it.  How to fix this?

John Connor
22.02.2017, 12:41
It might help if you attached a copy of the lisp routine to your next post so anyone interested in helping you doesn't have to go searching for it.  If I recall correctly that routine was developed back around 2000 or 2001.
John Connor2017-02-22 12:41:57

smiddendorf
22.02.2017, 16:54

http://www.turvill.com/t2/free_stuff/Link to the turvill Lisp site that includes the full .lsp file along with the source code. 

John Connor
22.02.2017, 16:57
Did you recently change the version of AutoCAD being used?Update.So like you I am running AutoCAD 2017.  I downloaded the GETPAT.lsp routine, opened a drawing that utilized a custom hatch pattern and proceeded to run GETPAT.  It successfully created a .PAT file for the hatch pattern.  There was no "bad argument" error message.  It worked as advertised.  Don't know why you had an error.  What kinds of troubleshooting steps did you take?  Such as....Did you try the routine on more than one hatch pattern?Did you test it against one of the standard AutoCAD hatch patterns (ex. - Stars)?Did you try downloading the lisp routine again?  Maybe your version became corrupted somehow.
John Connor2017-02-22 18:39:27

smiddendorf
22.02.2017, 19:15

I did completely delete the lisp routine and re-downloaded it.  No luck.  When trying it with various hatches a few times it asked me if I want to overright the pattern, but this was only a couple times after maybe 50 attempts on different hatches.  It also doesn't seem to work on standard hatches, but it wouldn't help me if it did.  A month ago I could GETPAT every hatch that I had (hatches I brought with me from another office), perfectly.  Now it doesn't recognize any of the ones I brought.  The only other difference I made was reinstalling cad2017 at the suggestion of Autodesk as a part of the solution they gave me to fix a Revit problem I was having.  Perhaps somehow the reinstall is the problem.  The .pat files are still stored in the same location as before, however.

John Connor
22.02.2017, 19:20
If you used GETPAT on every hatch you brought with you from another office then shouldn't you have copies of all those .PAT files on your hard drive?What do you mean it doesn't work on standard hatches?  Name a standard hatch it does not work on.I don't see why reinstalling AutoCAD would have any negative affect on the operation of the GETPAT lisp routine.

smiddendorf
22.02.2017, 23:34
If I knew the answers to your questions I wouldn't have needed to post anything on this forum to begin with.  No, the hatches I am looking for are not on my hard drive, perhaps because Autodesk instructed me to delete any Autodesk-related files prior to the reinstallation.  But GETPAT is supposed to give you access to hatches you DONT already have.  An example of a standard hatch that GETPAT does not work on is ANSI31, but who cares, I don't need GETPAT for standard hatches, I need it for what it was created for, which is custom hatches.  A month ago I could type GETPAT, and instantly have access to whatever hatch I selected (some of which are very complex) via executing a new hatch or matching properties with an existing hatch.  As of a few days ago that ability disappeared.I guess what I was hoping for was a solution, or maybe another .lsp routine that performs a similar function. 

John Connor
23.02.2017, 11:40
GETPAT does work, maybe not on your system but it does on every CAD workstation in our company.The fact that you did not back up the individual custom hatch patterns created for you previously by GETPAT is no one's fault but your own.  Numerous sources warn us to be careful about mixing custom files in with the AutoCAD installation files and suggest that if we are going to do so to always keep a backup of the custom files in a separate folder.  You failed to do this.  Consider it a hard lesson learned.I tested GETPAT on ANSI32 yesterday and it worked so I suspect that it would work on ANY standard hatch pattern but you are right, that's not what you need GETPAT for however your statement to the contrary was wildly incorrect.If GETPAT worked up until a few days ago then perhaps the problem is somehow related to a Windows update although that seems pretty farfetched.  None-the-less, it would be easy enough to troubleshoot.  Find a Windows restore point that predates the day you first encountered the problem and roll your system back...then test.Re: another lisp routine that does the same thing.  I think I came across one some time back but I would have to search my library of custom lisp routines to see if I retained a copy.  Sometimes even though I don't use certain routines in my day-to-day job a particularly unique routine will catch my interest and I'll download a copy just in case the day comes that someone else is looking for something similar.  When I get back to my CAD computer I'll see what I may have saved.  If I find anything of use to you I will upload it.
John Connor2017-02-23 11:41:24

John Connor
23.02.2017, 11:48
Well that was too easy.  Right here at the CADforum is a lisp routine called PatOut.  Details are as follows...The free LISP utility by CAD Studio - PatOut - can generate hatch pattern definition files in the .PAT format from your DWG
drawings. Any selected hatch will be converted to a separate PAT file
with the hatch definition. So you transfer hatch patterns between
drawings - simply reuse the PAT in the new drawing.
You can download PatOut from www.cadstudio.cz/download - load it with APPLOAD and start the PatOut command (see also SW Development). Now, don't you feel better already?
John Connor2017-02-23 11:49:21

John Connor
28.02.2017, 12:21
smid: Did you ever find a solution to your problem?  Did you fix GetPat or did you use the PatOut lisp routine I mentioned above?

smiddendorf
28.02.2017, 13:48

I didn't back up hatch patterns because I had GETPAT.  I suppose I should carry a box of band-aids with me every time I shave, you jerk, but I suppose I just enjoy living dangerously, you jerk.  Your stupid Patot doesn't work any better than GETPAT, even though you clearly don't believe I am having problems with it.  Go fuc%&^ yourself.  Jerk.

John Connor
28.02.2017, 15:00
Seems like somebody got up on the wrong side of the bed this morning.
John Connor2017-02-28 15:09:07

John Connor
28.02.2017, 15:07
I must be crazy given the name calling and swearing above but...Upload or attach a drawing with some hatch patterns whose definitions you would like extracted and I'll see what I can do for you. That's my final offer.

John Connor2017-02-28 16:07:28