@jyan2000 wrote:
... what should I do if I want Z= value to be ( + / - ) plus or minus 100 but data will shown as " Z: 145.00 - 100 = 45.00" ?
...
I'm not quite sure I understand exactly what you're asking [another sample image would be helpful], but you can construct such a string. To get what you show at the end, but using whatever the actual Z value is in place of the example 145.00, replace this line:
"Z=" (rtos (caddr pt) 2 2)
with this:
"Z: " (rtos (caddr pt) 2 2) " - 100 = " (rtos (- (caddr pt) 100) 2 2)
You could also have the routine ask for a value [positive or negative] in place of the 100, earlier:
(setq Zoffs (getdist "\nZ-coordinate plus/minus value: "))
and build the string to show that value and account for whether it's positive or negative [untested]:
"Z: " (rtos (caddr pt) 2 2) " " (if (minusp Zoffs) "-" "+") " " (rtos Zoffs 2 2) " = " (rtos (- (caddr pt) Zoffs) 2 2)
You could use (getreal) instead of (getdist) for the Zoffs value; (getdist) allows on-screen distance pick if desired, but for a negative value the User wouldn't be able to do that, but would need to type it in.
Kent Cooper, AIA