实在不知到如何向上滑出
希望这个让你满意
type
TForm1 = class(TForm)
Image1: TImage;
PopupMenu1: TPopupMenu;
N1: TMenuItem;
N2: TMenuItem;
N3: TMenuItem;
procedure Image1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.DFM}
procedure TForm1.Image1Click(Sender: TObject);
var p:tpoint;
begin
GetCursorPos(p);
form1.PopupMenu1.Popup(p.x,p.y);
end;
//image就是按钮,把他的PopupMenu设为PopupMenu1;