No worries, Peter; for a moment I was giddy that Autodesk finally support such functionality (in 2015 they added custom system variables via Autoloader), and I am unable to open attachments from my iPhone.
Cheers
|
No worries, Peter; for a moment I was giddy that Autodesk finally support such functionality (in 2015 they added custom system variables via Autoloader), and I am unable to open attachments from my iPhone.
Cheers
"How we think determines what we do, and what we do determines what we get."
Sincpac C3D ~ Autodesk Exchange Apps
Computer Specs:
Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000
Hence my question, as there was no Method Overload.
"How we think determines what we do, and what we do determines what we get."
Sincpac C3D ~ Autodesk Exchange Apps
Computer Specs:
Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000
You could create a lisp function with dot net with an overload.
Now that I am able to grab the value of "Width", is it possible to grab the "Y" location of a block?
I was pretty proud of myself to be able to take what you had and get the actual value that I needed by adding these lines.
(setq WidthValue (nth 5 lstCustomInfoSublists))
(setq WidthValue (nth 2 WidthValue))
(setq WidthValue (atof WidthValue))
(- WidthValue 10)
I'm sure that it could be done much cleaner and with some error trapping to verify that this value belongs to "Width". I'm not at that level yet, but will be working toward figuring it out.
Thanks for the help thus far.
Correct, sort of; there would still only be one LispFunction Method, which would call a Method Overload supplying ResultBuffer's contents in a Try\Catch block. AFAIK, you cannot Overload a LispFunction Method anymore than you can a CommandMethod Method (although I've admittedly never tried).
Interesting discussion, Peter.
Cheers
"How we think determines what we do, and what we do determines what we get."
Sincpac C3D ~ Autodesk Exchange Apps
Computer Specs:
Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000
So far this will get the correct DWGPROP, the Position of Left_Stop block, and return a value (Width of material - Left_Stop). I now need to figure out how to "push" that value to an attribute in the Pusher block. Any help will be much appreciated.
Code:(defun CustomInfoToList (/ intCustomInfo lstCustomInfoSublists ; List of Custom Information Pairs objSummaryInfo strPValue strPKey ) (command "DWGPROPS") (setq objSummaryInfo (SummaryInfoObject)) (repeat (setq intCustomInfo (vla-NumCustomInfo objSummaryInfo)) (setq intCustomInfo (1- intCustomInfo)) (vla-GetCustomByIndex objSummaryInfo intCustomInfo 'strPKey 'strPValue) (setq lstCustomInfoSublists (cons (list strPKey intCustomInfo strPValue) lstCustomInfoSublists)) ) (setq WidthValue (nth 5 lstCustomInfoSublists)) (setq WidthValue (nth 2 WidthValue)) (setq WidthValue (atof WidthValue)) ;;;;;code to get backstop position (get_origin "") (setq block_name "Left_Stop");JASON (setq block_ss (ssget "x" (list (cons 0 "INSERT")(cons 2 block_name)))) (if block_ss (setq Stop_Pt (trans (cdr (assoc 10 (entget (ssname block_ss 0)))) 0 1))) (setq Backstop_Pt (cadr Stop_Pt)) ;;;;;formula for pusher position (setq Pusher_Pos (- WidthValue Backstop_Pt)) )
Last edited by BlackBox; 2015-01-28 at 04:01 PM. Reason: Replaced [QUOTE] with [CODE] tags
"How we think determines what we do, and what we do determines what we get."
Sincpac C3D ~ Autodesk Exchange Apps
Computer Specs:
Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000
I'll let you know how far I get tomorrow. Why do there have to be so many parenthesis?! lol
"How we think determines what we do, and what we do determines what we get."
Sincpac C3D ~ Autodesk Exchange Apps
Computer Specs:
Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000