Jump to content

Possible to grab transparent command return result in variable?


MJLM

Recommended Posts

Hi,

 

I have made my fast selection routine that collects members of a network as a chain and returning as a selection set . I would like to get the returning ss running it as transparent, that is while already being inside an other routine on an active ssget prompt, type 'my_fast_selection_commad and get the ss coming from the transparent command. From what I have tried, it seems it is not possible?

 

Can a transparent command return anything apart from nil?

Link to comment
Share on other sites

So if I am reading this correctly you ant something like:

(not in code tags since this isn't really code, just the idea)

 

(defun c:testlisp ( / )

 [Do some setp stuff]

 (setq MySS (ssget... get selection se)

    [But can type in (my_fast_selection_command) in setq MySS (my_fast_selection_command)]

 [do more stuff]

)

 

I have something that will do this with an entsel, rather than a selection set I think - it might be able to be modified using SS

I think using a while loop and an initget night be working something like

 

 

(setq endloop "No")

(initget my_fast_selection_command)

(whle (= "No" endloop)

  (if getsting "my_fast_selection_command (progn (setq MySS (my_fast_selection_command))(setq endloop "Yes")))

  (setq MySS (ssget...))

);end while

 

 

Somthing like that if I remember what I did correctly - gives you smething to thinkaboutfor now anyway.

Link to comment
Share on other sites

Maybe this example of a erase shortcut note the transparent 'ZZZ must use single quote for transparent.

 

(defun c:zzz () (ssget "X" '((0 . "LINE"))))

 

Erase 'zzz Enter

  • Like 1
Link to comment
Share on other sites

8 hours ago, BIGAL said:

Maybe this example of a erase shortcut note the transparent 'ZZZ must use single quote for transparent.

 

(defun c:zzz () (ssget "X" '((0 . "LINE"))))

 

Erase 'zzz Enter

 

That's new to me! Thanks

Link to comment
Share on other sites

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...