Author Topic: How to put a lot's text figures (that's in excel) into the pure digital format?  (Read 18276 times)

0 Members and 1 Guest are viewing this topic.

jxphklibin

  • Guest
Now, I used another method, Only use this function, it can be very simple to solve my problem, the text figures can be automatically converted to the pure digital format, without changing the structure of OutPutDLst variables. Of course, there was no need to modify the vlxls-cell-put-value function, this function has no use.

The following is my code:
Code: [Select]
(defun Vlxls-Put-RowList (xlapp startrow startcol lst / sheet)
  (setq sheet (vlax-get-property xlapp "ActiveSheet"))
  (foreach itm lst
    (msxl-put-value2
      (vlxls-get-cell sheet startrow startcol)
      itm
    )
    (setq startcol (1+ startcol))
  )
)

(foreach item OutPutDlst (Vlxls-Put-RowList *xlapp* (1+ (vl-position  item outputdlst)) 1 item))

The code below and above the effect of equivalent:

(repeat   (length OutPutDlst)
  (setq   col  0
   item (nth *Tmp* OutPutDlst)
  )
    (Vlxls-Put-RowList *xlapp* (setq *Tmp* (1+ *Tmp*)) 1 item)
)