learn CmdLine for delphi
program Project1;uses
Windows;
var
text:string;
begin
text:='fuckgexx';
CmdLine:=PChar(text);
MessageBox(0,CmdLine,'StrParam Command',MB_OK);
{ TODO -oUser -cConsole Main : Insert code here }
//判断 参数个数
if ParamCount > 0 then
MessageBox(0,PChar(ParamStr(1)),'1st_param',MB_OK)
else
MessageBox(0,PChar('No paramete'),'1st StrParam Parameter', MB_OK);
Exit
end.
页:
[1]