Berat Posted March 26 Share Posted March 26 (edited) I have UserForm in AutoCad 2006, from which i Draw Polygons, Parcels etc, when I go to another PC, same code, same everything, UserForms just Draw some lines like numbers. Please also see the attached complete Program.rar. Please look this: https://shorturl.at/qR345 Program.rar Edited March 26 by Berat Quote Link to comment Share on other sites More sharing options...
BIGAL Posted March 28 Share Posted March 28 Please use zip easier to uncompress. Did not open rar. You probably need to look at your text style, the object is possibly there but the text is huge. Quote Link to comment Share on other sites More sharing options...
Berat Posted March 28 Author Share Posted March 28 Dear, Please find zipped file my program, so please find also one file Parcel.csv, when I try in my Pc, this is the results as below in Image.png, Programi.zip Parcela_00902-0.csv Quote Link to comment Share on other sites More sharing options...
BIGAL Posted March 30 Share Posted March 30 Try this (defun c:wow ( / csv->lst fname fo lst lst2 obj ptc) ; thanks to Lee-mac for this defun (defun csv->lst44 ( str / pos ) (if (setq pos (vl-string-position 44 str)) (cons (substr str 1 pos) (csv->lst44 (substr str (+ pos 2)))) (list str) ) ) (defun LWPoly (lst cls) (entmakex (append (list (cons 0 "LWPOLYLINE") (cons 100 "AcDbEntity") (cons 100 "AcDbPolyline") (cons 90 (length lst)) (cons 70 cls)) (mapcar (function (lambda (p) (cons 10 p))) lst))) ) (setq fo (open (getfiled " Select csv File" "" "csv" 20) "R")) (setq lst '()) (while (setq nline (read-line fo)) (setq lst (cons (csv->lst44 nline) lst)) ) (close fo) (setq lst (reverse lst)) (setq lst2 '()) (foreach val lst (setq lst2 (cons (list (atof (nth 1 val))(atof (nth 2 val))) lst2)) ) (LWPoly lst2 1) (command "zoom" "E") (setq obj (vlax-ename->vla-object (entlast))) (setq ptc (osnap (vlax-curve-getStartPoint obj) "gcen")) (setq area (strcat (rtos (vlax-get obj 'area) 2 2) "m\U+00B2")) (command "Text" ptc "" 0.0 area) (princ) ) Quote Link to comment Share on other sites More sharing options...
Berat Posted April 1 Author Share Posted April 1 Dear my Friends, Thank you very very much for your code and for everything else, but as you can see I have userform, i have a lot of buttons, commands etc etc, so I cant implement Lisp Codes within VBA userforms, so in this case I need VBA code to realize it. Thanks a lot Quote Link to comment Share on other sites More sharing options...
Berat Posted April 4 Author Share Posted April 4 ??? Quote Link to comment Share on other sites More sharing options...
BIGAL Posted April 4 Share Posted April 4 If your waiting for me I dabble in VBA spend 99% of time in lisp. So sorry can not help. Quote Link to comment Share on other sites More sharing options...
Berat Posted April 5 Author Share Posted April 5 Aha let's wait another people if anyone can help me to resolve this. Quote Link to comment Share on other sites More sharing options...
SLW210 Posted April 5 Share Posted April 5 I get this with your code. Quote Compile error: The code in this project must be updated for use on 64-bit systems. Please review and update Declare statements and then mark them with the PtrSafe attribute. SEE THIS Quote Link to comment Share on other sites More sharing options...
SLW210 Posted April 5 Share Posted April 5 Maybe you should give all details on the two computers and which one works. Quote Link to comment Share on other sites More sharing options...
Berat Posted April 11 Author Share Posted April 11 Which details I must check my friends please. Quote Link to comment Share on other sites More sharing options...
SLW210 Posted April 11 Share Posted April 11 All of them. Operating System and version, computer specifications, graphics card, etc. Did you read the information in the link I posted? Quote Link to comment Share on other sites More sharing options...
Berat Posted April 12 Author Share Posted April 12 Dear My Friends, First of all thank you for your help and supprot, I am not sure if is allowed, but I would like whenever you can, I can share my Screen and to see if you can resolve this please. I have read but I didn't understood sincerly. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.