Recent Posts

Pages: [1] 2 3 ... 10
AutoLISP (Vanilla / Visual) / Re: Strengthen the dimensioning
« Last post by CAB on Today at 07:03:34 pm »
Ditto  8)
AutoLISP (Vanilla / Visual) / Re: Strengthen the dimensioning
« Last post by Lee Mac on Today at 06:19:12 pm »
Looking good Stefan!  :-)
AutoLISP (Vanilla / Visual) / Re: If you are smart...
« Last post by GP on Today at 06:02:08 pm »
While waiting for a solution to be revealed, I suggest this inelegant way to find the "approximate" length of a sweep solid created with sweep path = polyline.

Code: [Select]
(defun c:test (/ S EL S2 SS Reg n S1 eS A_ L)
            (princ "\nSelect a 3D SOLID created with SWEEP command")
            (setq S (ssget  "_+.:S" '((0 . "3DSOLID"))))
            (setq S (ssname S 0))
            (eq (vla-get-SolidType (vlax-ename->vla-object S)) "Sweep")
            (setq EL (entlast))
            (setq SS (ssadd))
            (command "_copy" S "" "_non" "0,0" "_non" "0,0")
            (setq S2 (entlast))
            (command "_explode" S2)
            (while EL
                (if (setq EL (entnext EL)) (ssadd EL SS))    
            (setq Reg (ssadd))
            (repeat (setq n (sslength SS))
                (setq S1 (ssname SS (setq n (1- n))))
                (setq eS (cdr (assoc 0 (entget S1))))
                (if (= eS "REGION") (setq Reg (ssadd S1 Reg)))
            (if (= 2 (sslength Reg))
                    (setq A_ (vla-get-area (vlax-ename->vla-object (ssname Reg 1))))
                    (setq L (/ (vla-get-volume (vlax-ename->vla-object S)) A_))
            (vl-cmdf "_erase" SS "" )
            (princ (strcat "\nLength of the sweep solid: " (rtos L)))
AutoLISP (Vanilla / Visual) / Re: Strengthen the dimensioning
« Last post by Stefan on Today at 05:16:29 pm »
I have something, but it is not finished yet. Sorry...
.NET / Re: Request MySQL database integrated
« Last post by nekitip on Today at 02:41:37 pm »
If you know lisp, and have lisp things, and don't have the time for .net, then just do it in lisp. However, think about this in the long run...
As for MySQL, again - i'm not sure what is your experience with database: you have database server, one only, available to all. There you keep your lisp routines, and others connect and download. To do this in .NET there are, again, various ways to do it, one of wich is by having ".NET connector" downloaded from MySQL site, and included in your app. Users will also have to have it, and you can include MySQL connector instalation in your app. However, as I have said it - MySQL connector is GPL code.
Again, if you not sure about MySQL, and all you need is a simple SQL operations, you can download and start some variant of MS SQL server. There was a "compact" or something like that before... check it.

.NET / Re: Request MySQL database integrated
« Last post by cadplayer on Today at 12:08:04 pm »
thanks for your replay, what nekitip says comes in my direction. Iīm your opinion MickID, itīs more cleaner to do all in one. Sometimes, sorry I have only little praxis with .NET, I can write some LISP codes very fast. But I have to say, my library of lispfunctions is increased i a couple of years. But .NET I have done only windwows-applications in last year where I started.
So maybe I want go two ways:
F * build all methodes in LISP new in .NET (longer way, needs time :-P)
S * combine .NET with LISPfunctions (but this is pretty bad)

If I think to my colleagues on my company, that use my LISP function. I have done two things to avoid copyright my tools. In my dropbox I have saved serialkeys for every user, these keys reads in running mode. Also I have saved some important files (like diverse arx,vlx,dcl,odcl,dll files) dropbox/folder. These would be download in using procedure. So it sounds very complex, is it too.
I know with C# can I read strings from a MySQL database, but could I run them as LispMethodes in Acad ? And another question is, I expect that all users have to install MySQL-InstallerServer or ?
Is it maybe I saved the hole LISPapplication on CompanyServer and collect all user over MySQL serials ?
.NET / Re: Request MySQL database integrated
« Last post by nekitip on Today at 10:11:21 am »
With .NET you can call sql server, and receive binary or text field.
However, MySQL is usefull only if you have a large number of customers and want to organise lisps on one central place. (dont know if you can start listp in autocad from string, never tried).
But, MySQL doesn't have LGPL .NET connector, meaninig - you cannot sell your app.
If your intent was to do it for yourself, per machine, or per few users, you can use, as sugested, using SQLite.
There is also MS SQL server, available for free in several flavors... so...
AutoLISP (Vanilla / Visual) / Re: Strengthen the dimensioning
« Last post by 77077 on Today at 09:44:36 am »
Maybe need grread function. but  i can't.
.NET / Re: Request MySQL database integrated
« Last post by MickD on September 20, 2014, 06:59:42 pm »
It sounds to me that you would like to automate calling your lisps to run 'routines'. Why not just do this in lisp? If you are using .net for performance then calling lisps from within won't be much help.

If you only need your lisp for some parts of your routine but you want to use .net to build routines I would consider re-writing those lisp methods in .net just to clean things up and perhaps improve performance.

As far as a db goes, MySql would be overkill, I'd look into NoSql or SqlLite which do not require a fully fledged server. Yes, a database will help with sorting function names, I'm not sure if you can load a lisp from a db though, never tried.

Another option to help organise your lisp functions and avoid all the complexity of a db could be to use some kind of name spacing convention to group and name your lisp functions.
Whatever you decide try not make things too hard for yourself and keep it simple :)
.NET / Request MySQL database integrated
« Last post by cadplayer on September 20, 2014, 01:52:28 pm »
My idea to save all my AutoLISP function in a MySQL database. I think it could be very useful if I have more control of all functions collect in a database.

First thing I wondering, if itīs possible to connect MySQL server via .C# and recall Autolisp functions within ?
- I know that I can run a AutolispCommand ex.:
Document doc = AcAp.DocumentManager.MdiActiveDocument;
            doc.SendStringToExecute("(setvar \"CMDECHO\" 0)\n", true, false, true);
Have you think about to use Autolisp within a .NET methode?

Sec. could database have a intelligence to sort by function type, or if I looking after keys maybe: find all string-functions, list-function, lambda-methods ...

Hopefully itīs not much confused I wrote, I beginning build a db from skretch. Can somebody help me.
Pages: [1] 2 3 ... 10