(Delphi) How to use DosCommand Component? [closed]

半世苍凉 提交于 2019-12-14 03:33:32

问题


I have Installed https://github.com/TurboPack/DOSCommand on Rad Studio Berlin 10 update 2 but I cannot find out how to use it. I have tried playing around with it and I have searched through google looking for examples but I can't find any.


回答1:


Unfortunately your question does not have a detailed description. If you have the component installed successfully it should appear in the component palette. Please place it on your form, adjust properties in object inspector and call Execute.

BTW have you read "How to use it" and "Example" comments in the unit header?

 *******************************************************************
  How to use it :
  ---------------
  - just put the line of command in the property 'CommandLine'
  - execute the process with the method 'Execute'

Example

  Example : Make a dir :
  ----------------------
  - if you want to get the Result of a 'c:\dir /o:gen /l c:\windows\*.txt'
  for example, you need to make a batch file
  --the batch file : c:\mydir.bat
  @echo off
  dir /o:gen /l %1
  rem eof
  --in your code
  DosCommand.CommandLine := 'c:\mydir.bat c:\windows\*.txt';
  DosCommand.Execute;


来源:https://stackoverflow.com/questions/41652193/delphi-how-to-use-doscommand-component

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!