Author Topic: Question 30 goes here  (Read 37095 times)

0 Members and 1 Guest are viewing this topic.

LUCAS

  • Newt
  • Posts: 32
Re: Question 30 goes here
« Reply #75 on: February 17, 2006, 02:45:29 AM »
Selfload is like a virus. Please delete this topic.

Mark

  • Custom Title
  • Seagull
  • Posts: 28762
Re: Question 30 goes here
« Reply #76 on: February 17, 2006, 12:33:18 PM »
Selfload is like a virus. Please delete this topic.

Done!
TheSwamp.org  (serving the CAD community since 2003)

LUCAS

  • Newt
  • Posts: 32
Re: Question 30 goes here
« Reply #77 on: February 17, 2006, 07:05:11 PM »
;;How to stop autoload of vlx?
;;I find nothing.
(vl-load-com)
(if DWGREACTOR
  (vlr-remove DWGREACTOR)
)
(setq DWGREACTOR
       (vlr-dwg-reactor
    (vla-get-database
      (vla-get-activedocument
        (vlax-get-acad-object)
      )
    )
    '((:vlr-begindwgopen . STOP_LOAD))
       )
)
(if DWGREACTOR1
  (vlr-remove DWGREACTOR1)
)
(setq DWGREACTOR1
       (vlr-dwg-reactor
    (vla-get-database
      (vla-get-activedocument
        (vlax-get-acad-object)
      )
    )
    '((:vlr-enddwgopen . STOP_LOAD1))
       )
)
(if DWGREACTOR2
  (vlr-remove DWGREACTOR2)
)
(setq DWGREACTOR2
       (vlr-editor-reactor
    NIL
    '((:vlr-commandwillstart . STOP_LOAD2))
       )
)
(vlr-set-notification DWGREACTOR2 'ALL-DOCUMENTS)
(vlr-set-notification DWGREACTOR1 'ALL-DOCUMENTS)
(vlr-set-notification DWGREACTOR 'ALL-DOCUMENTS)
(defun STOP_LOAD (CALLER CMDSET)
  (setq pp (vl-list-loaded-vlx))
  (print pp)
  (print CALLER)
  (print CMDSET)
)
(defun STOP_LOAD1 (CALLER CMDSET)
  (setq pp (vl-list-loaded-vlx))
  (print pp)
  (print CALLER)
  (print CMDSET)
)
(defun STOP_LOAD2 (CALLER CMDSET)
  (print CALLER)
  (print CMDSET)
)


Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: Question 30 goes here
« Reply #78 on: February 20, 2006, 04:24:00 AM »
LUCAS,

What are you trying to do ?

< note WHAT not HOW >


kdub, kdub_nz in other timelines.
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: Question 30 goes here
« Reply #79 on: February 20, 2006, 04:28:48 AM »
Selfload is like a virus. Please delete this topic.

.. delete this topic. ..
LUCAS, can you clarify this comment. ?

< comment removed .. waiting for clarification >
kdub, kdub_nz in other timelines.
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

LUCAS

  • Newt
  • Posts: 32
Re: Question 30 goes here
« Reply #80 on: February 20, 2006, 08:02:08 PM »
See the autoload code of Luis.Can you stop the alert message?
If your answer is no.
You will in danger to open dwg.
If someone make a bad code (like to rename all files name & del some system files)

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: Question 30 goes here
« Reply #81 on: February 20, 2006, 08:12:20 PM »
That < bad code >  is an issue with any program that you are not familiar with .. VB, EXE, ARX, C#, .NET, VLX, FAS, complied LSP, etc ..

Removing this topic will not solve the problem.

Knowledge and testing WILL solve the problem.

... personal opinion.

 
kdub, kdub_nz in other timelines.
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

Chuck Gabriel

  • Guest
Re: Question 30 goes here
« Reply #82 on: February 20, 2006, 08:24:07 PM »
I'm inclined to agree with Kerry.  The tool isn't inherently evil, though it could be put to mischievous uses.

Also, how are we supposed to disarm any unruly code that makes use of the mechanism, if we don't study and understand how it works?

LUCAS

  • Newt
  • Posts: 32
Re: Question 30 goes here
« Reply #83 on: February 20, 2006, 09:28:55 PM »
;;OK!ALL USER IN DANGER.
;;CODE FOR AUTOLOAD,BY LUCAS
(vl-load-com)
(vlr-pers (vlr-dwg-reactor
       NIL
       '((:vlr-enddwgopen . BEGIN)) ;ANYNAME
     )
)
(defun C:BEGIN_OPEN ()
  (alert "This is only a test")
  (princ)
)
(alert "This is only a test")
(princ)

LE

  • Guest
Re: Question 30 goes here
« Reply #84 on: February 20, 2006, 10:01:55 PM »
See the autoload code of Luis.Can you stop the alert message?
If your answer is no.
You will in danger to open dwg.
If someone make a bad code (like to rename all files name & del some system files)


Hi Lucas;

I understand your concern, please read the whole thread, in here is also the solution to get rid of this alternative.

 :-)

LE

  • Guest
Re: Question 30 goes here
« Reply #85 on: February 20, 2006, 10:11:17 PM »
And by the way.... this has always been part of the function vlax-ldata-put, what happens is that in the help file, is not well explained... notice the optional argument for [private] data

LUCAS

  • Newt
  • Posts: 32
Re: Question 30 goes here
« Reply #86 on: February 20, 2006, 10:42:44 PM »
And by the way.... this has always been part of the function vlax-ldata-put, what happens is that in the help file, is not well explained... notice the optional argument for [private] data

Autoload not only using vlax-ldata-put

(vlr-pers (vlr-dwg-reactor
       NIL
       '((:vlr-enddwgopen . BEGIN)) ;ANYNAME
     )
)


LE

  • Guest
Re: Question 30 goes here
« Reply #87 on: February 21, 2006, 09:23:15 AM »
Sorry Lucas;

But can not understand what you are trying to say.

What is the code you posted supposed to do? and by the way it is very easy to get rid of that reactor... is that your point?


Thanks.
« Last Edit: February 21, 2006, 09:26:42 AM by LE »

Kerry

  • Mesozoic relic
  • Seagull
  • Posts: 11654
  • class keyThumper<T>:ILazy<T>
Re: Question 30 goes here
« Reply #88 on: February 21, 2006, 09:50:45 AM »

Is a FAS file.


Thanks Luis ..

.. but can we trust it ?  :lol:  .. you know I'm joking in this case, right !


BUT, generally unless I know <of> the author, I won't download compiled or protected code.
come to think of it, even if I 'know' the author, I still like to know WHAT a routine is actually doing before I use it .. ..
 ... so I s'pose I'm a little paranoid too.


afterthought : 'knowledge is power' so they say
but  Imagination is  more important than knowledge ... Albert  Einstein
kdub, kdub_nz in other timelines.
Perfection is not optional.
Everything will work just as you expect it to, unless your expectations are incorrect.
Discipline: None at all.

LE

  • Guest
Re: Question 30 goes here
« Reply #89 on: February 21, 2006, 09:56:38 AM »

Is a FAS file.


Thanks Luis ..

.. but can we trust it ?  :lol:  .. you know I'm joking in this case, right !


BUT, generally unless I know <of> the author, I won't download compiled or protected code.
come to think of it, even if I 'know' the author, I still like to know WHAT a routine is actually doing before I use it .. ..
 ... so I s'pose I'm a little paranoid too.


I know is hard sometimes to get rid of some useful functions [at least to me].... anyways no big deal and to show that I am not hidding anything at all, hope that would help as in open mode...  :kewl:

« Last Edit: February 21, 2006, 10:32:00 AM by LE »