Annotation Text with multiple lines.

Hi,

I am trying automate an analysis. In the loop, I do multiple curve fits and record the values in a string for latter annotation.

For example I have a string, called labels, that is two lines and looks like this

P032 = (193 ± 4.07) + (-201 ± 9.58)*exp(- Q/(12.2 ±1.21))
F001 = (282 ± 6.19) + (-347 ± 23.4)*exp(- Q/(3.39 ±0.426))

if I create an annotation using dynamic text \{labels} only the first line of the text is show in the annotation.

P032 = (193 ± 4.07) + (-201 ± 9.58)*exp(- Q/(12.2 ±1.21))


How do I get both (all) lines of the text string to show up?

Andy
A simple way is to use two dynamic escape codes, as in
•mylabel1="P032 = (193 ± 4.07) + (-201 ± 9.58)*exp(- Q/(12.2 ±1.21))"
•mylabel2="F001 = (282 ± 6.19) + (-347 ± 23.4)*exp(- Q/(3.39 ±0.426))"

TextBox/C/N=text0/A=MC "\\{mylabel1}\r\\{mylabel2}"


I tried using various \r\n new line escape codes in a single dynamic string without success.
Hi,

The code really needs to handle a variable number of lines. I notice if I go to the command line and use

•TextBox/C/N=text1/F=0/S=2/H={0,2,10}/A=MC labels

I do get the test to show correctly. So I am examining if this could be a work around.

Andy
Three things:

1) did you try TextBox ... "something\\r next line"?

2) What about using AppendText?

3) is it really necessary to use globals and \{expr\} syntax?


--Jim Prouty
Software Engineer, WaveMetrics, Inc.