PureBytes Links
Trading Reference Links
|
At 3:59 PM -0500 12/16/01, Jerry wrote:
>I guess I spoke too soon. They do have the window they have just removed the
>functions and any reference in the dictionary.
While you were finding that, I figured out how to draw the text on
the right side of the screen. The code below does it.
It didn't know what to do with the newline command so I had to draw
multiple lines from an array - a bit of a kludge but it works.
(See attached GIF.)
You need to allow space at the right side of your screen in the
Format Window - Properties dialog to leave space for the text. You
also need to save the values for the bar you want to monitor somehow
and use it the the code below. I just plotted the values for the last
bar but you could plot anything.
Bob Fulks
Vars: SCo1(""), {String for Condition1 value}
SCo2(""), {String for Condition2 value}
SCo3(""), {String for Condition3 value}
ID(0), HH(0), LL(0), Loc(0), Line(0), j(0);
Array: StrArr[10](""); {Output string array}
if LastBarOnChart then begin
if Condition1 then SCo1 = "TRUE" else SCo1 = "FALSE";
if Condition2 then SCo2 = "TRUE" else SCo2 = "FALSE";
if Condition3 then SCo3 = "TRUE" else SCo3 = "FALSE";
StrArr[1] = "Date = " + NumToStr(Date, 0);
StrArr[2] = "Time = " + NumToStr(Time, 0);
StrArr[3] = "High = " + NumToStr(High, 2);
StrArr[4] = "Low = " + NumToStr(Low, 2);
StrArr[5] = "Cond1= " + Sco1;
HH = Highest(High, 100); {Determine where to draw text}
LL = Lowest(Low, 100);
Line = (HH - LL) / 10;
Loc = HH;
for j = 1 to 5 begin
ID=Text_New(Date, Time, Loc - j * Line, StrArr[j]);
Value1 = Text_SetColor(ID, Tool_Red);
Value2 = Text_SetStyle(ID, 0, 0);
end;
end;
Attachment:
Description: "Jerry.gif"
|