Re:Popup menu calling popup
Steve
Use the onmousedown event for whatever object the mouse is clicking :-
procedure TForm1.FormMouseDown(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
var
NewLabel: TLabel;
begin
NewLabel := TLabel.Create(Form1);
NewLabel.Parent := Self;
NewLabel.Left := X;
NewLabel.Top := Y;
NewLabel.Caption := '(' + IntToStr(X) + ',' + IntToStr(Y) + ')';
NewLabel.Visible := True;
end;
This gives you the coordinates, hope this helps
Tim Newton
http://www.btinternet.com/~timn
Quote
Steve Stone wrote:
> How can get the proper screen cords for a contorl so manually calling
> Popup will place the popup menu next to the control you want.
> Thanks ..