How to entmake object with RGB color (OLE Color) ?

I use  lisp code below to entmake text with OLE color in AutoCAD :

(defun EntmakeText ()
(entmake
  (list
    (cons 0  "TEXT")
    (cons 1  "Color 0,243,92")
    (cons 40 10)
    (cons 7  "Standard")
    (cons 8  "0")
    (cons 50 0)
    (cons 10 (list 0 0 0))
    (cons 11 (list 0 0 0))

      ;RGB COLOR 0,243,92 = OLE COLOR 62300
    (cons 420 62300)


    (cons 72 1)
    (cons 73  0)))
)
;entmake text
(EntmakeText)

It doesn't work with bricscad V9.How can I set OLE or RGB color to object with entmake function ?

Comments

  • I solved problem. The code should include:   (cons 62  100) and (cons 420 62300).

    (defun EntmakeText ()
    (entmake
      (list
        (cons 0  "TEXT")
        (cons 1  "Color 0,243,92")
        (cons 40 10)
        (cons 7  "Standard")
        (cons 8  "0")
        (cons 50 0)
        (cons 10 (list 0 0 0))
        (cons 11 (list 0 0 0))

          ;RGB COLOR 0,243,92 = OLE COLOR 62300
        (cons 420 62300)

      ;index color ,

        (cons 62  100)


        (cons 72 1)
        (cons 73  0)))
    )
    ;entmake text
    (EntmakeText)

This discussion has been closed.