Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Salvare reattore con file dwg

3 REPLIES 3
Reply
Message 1 of 4
Lupo76
296 Views, 3 Replies

Salvare reattore con file dwg

Hello everyone,
I use the following code to assign a reactor to an object.
Now I noticed that if I close the dwg file after you successfully saved, when I open even if I load the lisp, the reactor does not work.

 

Another problem: when I use the command "erase" or "explode" the reactor is started twice, why?

you can run it at once?

 

(setq marReactor
   (vlr-object-reactor (list (vlax-ename->vla-object oggmar)) "TEST" 
      '(
           (:vlr-erased . reactor_upd)
           (:vlr-modified . reactor_upd)
        )
   )
)
3 REPLIES 3
Message 2 of 4
adam.nagy
in reply to: Lupo76

HI,

 

It's because deleting an entity is basically just setting a flag on it saying that it's erased.

So the actually object reactor messages are:

- Opened for modify

- Erase

- Modified

- Object Closed

 

I hope this explains.

 

Cheers,

Adam Nagy

Autodesk Developer Network



Adam Nagy
Autodesk Platform Services
Message 3 of 4
Lupo76
in reply to: adam.nagy

Thanks for the reply,
I was definitely helpful, but I could not solve the problem.

The object that I have to cancel, is a block with attributes
The reactor should behave in this way:
1. The user starts the command "erase", select the object and hit return
2. The reactor part, reads the value of an attribute of the selected block, and performs other operations with this
3. The object is removed permanently.

Unfortunately I can not understand how to control the various events.
In particular, I can not read the value of the attribute of the block before it is deleted.
Can you help me?

Message 4 of 4
Lupo76
in reply to: Lupo76

I've lost more hours of work to try and try again.
I have almost completed my application and now I'm still with this problem.

Can it be so difficult?
It seems to me that very little missing.

Do you have any advice?
Okay any information that may help.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost