ClearOutputWindow()

View as Markdown

Definition

Clears all data from the NinjaTrader Output Window.

The ClearOutputWindow() method only targets the Output tab most recently determined by set PrintTo property.

Method Return Value

This method does not return a value.

Syntax

ClearOutputWindow()

Examples

1protected override void OnStateChange()
2{
3 if (State == State.SetDefaults)
4 {
5 Name = "Examples Indicator";
6 Description = @"An indicator used to demonstrate various NinjaScript methods and properties";
7 }
8 else if (State == State.Configure)
9 {
10 AddDataSeries(BarsPeriodType.Minute, 5);
11 }
12
13 else if(State == State.DataLoaded)
14 {
15 //clear the output window as soon as the bars data is loaded
16 ClearOutputWindow();
17 }
18}