jlobo 发表于 2022-7-7 15:32:39

Load and Unload .arx aplicatio

I have few .arx applications for AutoCAD. In these applications few are menu based and others are command line. Now what I am trying to do is,

[*]Load the .arx app,
[*]run it and then
[*]unload it once the .arx application runs through a LISP command. .arx applications run once the user clicks on the tabs that are provided..arx applications are written in VC++.
Now I have a lisp file, which gets loaded once the user starts AutoCAD. In the lisp files I have declared these functions for various .arx applications;
 
(defun c:XYZ_program() (command) (command) (arxload "C:/ABC/XYZ.arx") (command "XYZ_program") (arxunload "XYZ.arx") )
 
It works fine for Programs which need input data from Menu based forms, but says error unloading xyz.arx for programs which need command line input.
I was wondering if there were any commands in LISP that will make sure arxunload "XYZ.arx" will execute only once (command "XYZ_program") is executed.
 
I am not sure on how to approach this problem. Any help with the same would be greatly appreciated.
 
I have also discussed this question with others in the following link, but did not find much of help. http://stackoverflow.com/questions/17602443/loading-and-unloading-the-arx-file-with-lisp
 
You can have a look at it, just to gather some information, in which direction were we heading.
页: [1]
查看完整版本: Load and Unload .arx aplicatio