Ads 468x60px

Smaller time frame always follow the bigger time frame. It's better wait be patience to enter in position than risk with BIG SL. Having strong trading discipline and taking losses when necessary is a sign of serious trading approach

Saturday, August 11, 2012

CREATE YOUR OWN HINTS


If you don't quite like the way how Delphi's default hints look like, you can use THintWindowcomponent to create your own customized hint window. Here's an example: 
var
  h : THintWindow;
  r : TRect;
begin
  with r do
  begin
    //
    // set the position and size
    // of the hint window
    //
    left   :=  10;
    top    :=  50;
    right  := 200;
    bottom := 100;
  end;
  h := THintWindow.Create( Self );
  with h do
  begin
    //
    // set the background color
    //
    Color := clRed;

    ActivateHint( r, 'hi there!' );

    //
    // perform your tasks here
    // before closing the hint window
    //
    MessageBox( 0,
      'Press any key to close the '
      + 'hint window',
      'THintWindow',
      MB_OK );
      
    ReleaseHandle;
    Free;
  end;
end;

comments