Hallo rpor66,
Ich änderte die Logik der Routine, jetzt benutze ich nicht mehr den Befehl "ändern", um den vorhandenen Text zu ersetzen, aber ich schreibe einen neuen Text genau an dem Ort, an dem der bestehende ist.
da im Design der Stil "arial" gesetzt ist, sollte ein neuer Text in diesem Stil geschrieben werden.
stattdessen ist der Text noch im Stil "txt"!
wenn stattdessen schreibe ich einen Text mit dem Befehl "text normalerweise, ich bekomme eine Zeichenkette im "arialen" Stil.
ein großes Problem statt, ist, dass durch das ungewöhnliche Verhalten der Routine sicher, abhängig davon, wie der ausgewählte Text abgefangen wird.
Wenn der Zoom auf einem bestimmten Wert ist, funktioniert alles gut, sonst wird der Novo-Text nicht geschrieben oder ein Kreis wird nicht gezeichnet.
Ich bin sicher, dass Sie die Lösung für Probleme finden.
Code:
(defunc c:reference (/ fc1 fc2 fc3 control1 heutiger Datumsstart pdop fp3 list txt1 nomad xlist primed txtdata name ecef gaussboaga control1 fp2 notex secondline reference and control3 fpr newtext fp1 fp5 ind cnt system namex ganze texting)
(setq osmode (getvar "osmode")
(falls)
(falls) osmode 16384)
(Setvar "osmode" (- osmode 16384))
)
)
(Sectq Referenz nil)
(setq station nil)
(falls)
(Progn)
(Alert "Sie müssen zuerst durchführen > Steuerbefreiung <")
(Auszug)
)
)
(setq baseline nil)
(Sekten erhöhen nil)
(Setq System ")
;;---------------------------------------------------------------------------------------------------------------------------------------------------------
(setq fc3 (findfile "c:\\\\\\autocadsupport\\config\\\\\config.dat"))
(falls fc)
(Progn)
(setq fp1 (eröffnet "c:\\\\\autocadsupport\\config\\\config.dat" "r"))
(setq baseline (read-line fp1))
(setq-Anhebung (read line fp1))
(setq system (readline fp1))
(Schließe fp)
)
)
(falls)
(Progn)
(Alert "Referenzname (Basislinie) fehlen!")
(Auszug)
)
)
(wenn (= nil ansteigen)
(Progn)
(Alert "Wert der fehlenden Zunahme!")
(Auszug)
)
)
;;---------------------------------------------------------------------------------------------------------------------------------------------------------
(setq fc1 (findfile "c:\\\\\autocadsupport\\\\\datirilievo.dat"))
(falls fc)
(vl-file-delete "c:\\autocadsupport\dati\datirilievo.dat")
)
(setq fc2 (findfile "c:\\\autocadsupporto\dati\\resposta.dat"))
(falls fc)
(vl-file-delete "c:\\autocadsupport\\dati\resposta.dat")
)
(falls)
(Progn)
(Alert "die Referenzlinie wurde bereits eingefügt")
;(Ausgang)
)
)
(startapp "c:\autocadsupporto\\\\\\daticompleti.exe "c:\\autocadsupport\\\\\\\daticompleti.tkn")
(Setq Station ")
(setq notax)
(seq control1 nil)
(while (= Steuerung 1 nil)
(setq control1 (findfile "c:\\\autocadsupport\\\\datirilievo.dat"))
;
(falls (/= control1 nil)
(Progn)
(setq fp3 (open "c:\\\autocadsupport\\\dati\datirilievo.dat" "r"))
(setq aktuelles Datum (read-line fp3))
(setq beginnt jetzt (read-line fp3))
(setq orafine (read line fp3))
(setq pdop (read-line fp3))
(setq station (read-line fp3))
(setq notax (read line fp3))
(Schließe fp)
), prog
)
(Setq-Liste nil)
(sing)
(= Liste nil)
(Setq-Liste (entget (entsel))))
)
(setq xlist (assoc -3 list)
(setq point1 (cdr (assoc 10 list))
(setq xd_ent (cdr -3 list))
(setq txtdata (car))
(setq string)
(setq txt1 (assoc 1 list)
(setq primed (car txt1))
(princ "\n")
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >
(princ list)
(princ "\n")
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >
(princ string)
(setq nomex (cdr)
(Satzart des Punktes (nth 2 txtdata))
(Satzanteil (cdr (nth 3 txtdata)))
(setq ecef (nth 4 txtdata))
(setq gaussboaga (cdr 5 txtdata))
(Setq Controllerstz (nth 6 txtdata)))
(setq controlpt (nth 7 txtdata)))
(Satzq cxb (Substr. Ecef 1 11)
(setq cyb (substr ecef 13 11)
(Satzq czb (Untergrenze ecef 25 11)
(setq cxbb (atof cxb))
(setq cybb (atof cyb))
(setq czbb)
(setq note2 (strcat nomex notax " - " station))
(setq Referenz (strcat "1|" Station "0.000" ecef "0.0000,000|[WGS84-RTF2000] "Note2 "|"
(setq secondlinea (strcat "6|l1|" heutiges Datum "-" jetzt beginnen "s" das heutige Datum "-" jetzt beenden "rtrtk|pdop=" pdop "|")
(Setq Name (strcat nomex " - " Station))
(setq textstation (strcat station " - (falls selbst)))))
(Befehl "_circle" gaussboaga "0.15")
(setq baseline station)
(Befehl "_text" Punkt1 0.40 0 Station)
(Befehl "_change" "_last" "_p" "_c" "_blue"")
;(Befehl "_change" "_last" """ """ "arial" """")
;;---------------------------------------------------------------------------------------------------------------------------------------------------------
(setq Namensgebung (entlast))
(Seq Objekt "Gruppe")
(wenn nicht (tblsearch "appid" object)
(Entfernungsobjekt)
)
(setq oldlist (entget nomeentita)
(setq np (assoc 1 oldlist)
(Satzname (cdr np))
(setq xyz (cdr 10 oldlist))
(setq gaussboaga (strcat (rtos (car xyz)) "," (rtos (cadr xyz)))
(Eingabe der Daten (Liste -3 (cons 1000 point name) (cons 1000 "point 2d") (cons 1000 Quote) (cons 1000 "-----------------------") (cons 1000 gaussboaga) (cons 1000 station))))
(Setq neue Liste)
(entmod newlist)
;;---------------------------------------------------------------------------------------------------------------------------------------------------------
(setq fp1 (open "c:\\\autocadsupport\\\\librettopregeo.dat" "a"))
(Referenz der Schreibzeile fp1)
(writing line secondline fp1)
(Schließe fp)
(setq fp5 (open "c:\\\\\autocadsupport\\\contatori\\counter.dat" "w"))
(writing line baseline fp5)
(Schreiblinienerhöhung fp5)
(Schließe fp)
(setq ind "x")
(setq index (strcat ind nomex))
(seq primariga) 1)
(Befehl "_circle" Punkt1 "1.00")
(Alert "line grundlegende Daten gespeichert - bereit zum Einfügen von Punkten")
)
Danke.