Message 1 of 5
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello everyone,
I have started to create my own routines recently, and I cannot make any improvement with it since some days ago. So if anyone could help me I would be very thankful.
I need my routine to select all of the texts on a layer called "LAYER1", and to apply one command that I have created. The problem is that my command accepts variables like string, and it takes one by one (for now...).
My command it´s the next:
(defun C:TEST() (setq VIG_TEX_OLD (getstring "Click en el texto a cambiar: ")) (setq INDICE_VIG_TEX_OLD (vl-string-position (ascii ":") VIG_TEX_OLD)) (if (= INDICE_VIG_TEX_OLD 5) (setq NOMBRE (substr VIG_TEX_OLD 3 3) DIMENSION (substr VIG_TEX_OLD 8 7)) (setq NOMBRE (substr VIG_TEX_OLD 3 4) DIMENSION (substr VIG_TEX_OLD 9 7))) (setq VIGAS_TEXTO_NUEVO (strcat "V" NOMBRE "-" DIMENSION)) (setq VIG_TEX_OLD NIL) (setq INDICE_VIG_TEX_OLD NIL) (setq NOMBRE NIL) (setq DIMENSION NIL) (print VIGAS_TEXTO_NUEVO) )
ASV
Solved! Go to Solution.