delphi xe7 fmx 클립보드로 복사

836 단어 Delphi/Win32SDK
unit Unit1;

interface

uses
  System.SysUtils, System.Types, System.UITypes, System.Classes, System.Variants, System.Rtti,
  FMX.Types, FMX.Controls, FMX.Forms, FMX.Graphics, FMX.Dialogs, FMX.StdCtrls, FMX.Platform;

type
  TForm1 = class(TForm)
    Button1: TButton;
    procedure Button1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.fmx}

procedure TForm1.Button1Click(Sender: TObject);
var
  Clipboard: IFMXClipboardService;  //  FMX.Platform
  Value: TValue; // System.Rtti
begin
  if TPlatformServices.Current.SupportsPlatformService(IFMXClipboardService,
IInterface(Clipboard)) then
  begin
    Value := TValue.From('http://jondy.net');
    Clipboard.SetClipboard(Value);
  end;
end;


end.

좋은 웹페이지 즐겨찾기