Jump to content

Search the Community

Showing results for tags 'command prompt'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Delphi Questions and Answers
    • Algorithms, Data Structures and Class Design
    • VCL
    • FMX
    • RTL and Delphi Object Pascal
    • Databases
    • Network, Cloud and Web
    • Windows API
    • Cross-platform
    • Delphi IDE and APIs
    • General Help
    • Delphi Third-Party
  • C++Builder Questions and Answers
    • General Help
  • General Discussions
    • Embarcadero Lounge
    • Tips / Blogs / Tutorials / Videos
    • Job Opportunities / Coder for Hire
    • I made this
  • Software Development
    • Project Planning and -Management
    • Software Testing and Quality Assurance
  • Community
    • Community Management

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Delphi-Version

Found 2 results

  1. I am trying to hide console input when a user has to enter a password in a command prompt window. I had the bright idea of redirecting the output of the command prompt to the NUL file but this code does not work even though you can execute the function without error. I am sure there used to be an easy way to do this! Do forget to include windows in the uses clause. Thanks for any help in advance Jack T function GetPassWordInput:String; var C:Char; S:String; H,HNULL:Cardinal; B:BOOL; begin HNULL := CreateFile('NUL',GENERIC_WRITE,FILE_SHARE_WRITE,nil, OPEN_EXISTING, FILE_ATTRIBUTE_SYSTEM,0); Assert(HNULL <> 0,'CREATING NUL FILE FAILED'); H:= GetStdHandle(STD_OUTPUT_HANDLE); B:=SetStdHandle(STD_OUTPUT_HANDLE,HNULL); Assert(B,'Set standhard handle failed to assign HNULL'); try begin repeat Read(C); if C=#8 then begin if Length(S)>1 then begin S:=LeftStr(S,Length(S)-1); end; end else if C<>#13 then begin S:=S+C; end; until C=#13; end finally begin SetStdHandle(STD_OUTPUT_HANDLE,H); CloseHandle(HNULL); end; end; Result := S; end;
  2. Giorgi Chapidze

    Set pipeline between UI and cmd.exe

    Hi! I am developing a simple editor application in which you can type Pascal code and click the compile button, which will connect cmd.exe in the background and compile a .pas file via freepascalcompiler. I have two separate TMemo components. one for writing source code and a second read-only component for showing compilation messages. To sum up, I want to execute the "fpc file_name. pas" command in the background and then grab the compiled messages and display them on the UI. How can I achieve such behavior? https://github.com/gchapidze/fmx-pascalIDE
×