Recent

Author Topic: How to use a input file?  (Read 8309 times)

NeoLee

  • Guest
How to use a input file?
« on: November 05, 2005, 08:58:47 am »
The program I built needs a input file. But I do not know how to set the options in the IDE.
  Is it in the Evironment options or Debugging options ?
  And where to download a Chinese language pack?
 Thank you!

matthijs

  • Hero Member
  • *****
  • Posts: 537
RE: How to use a input file?
« Reply #1 on: November 05, 2005, 11:09:53 am »
Go to Run -> Run Parameters.
In the inputbox "Commandline parameters" enter the name of the file with complete path.
Press OK
Press Run.
To make use of the parameter use ParamStr(1), as ParamStr(0) is the application exename.
What's in a sig? Would my posting look less if it didnot have a sig? (Free after William S.) :)

:( Why cannot I upload my own Avatar? :(

CCJ

  • Newbie
  • Posts: 6
RE: How to use a input file?
« Reply #2 on: November 13, 2005, 01:33:02 pm »
I don't quite understand you.  Then how to use "ParamStr(1)" as an input file?  Could you give me some expamles?

matthijs

  • Hero Member
  • *****
  • Posts: 537
RE: How to use a input file?
« Reply #3 on: November 13, 2005, 03:10:59 pm »
You could do something like this:
Code: [Select]

  AssignFile(F, ParamStr(1));
  Reset(F);
  // Do your stuff
  CloseFile(F);
What's in a sig? Would my posting look less if it didnot have a sig? (Free after William S.) :)

:( Why cannot I upload my own Avatar? :(

Marc

  • Administrator
  • Hero Member
  • *
  • Posts: 2584
Re: How to use a input file?
« Reply #4 on: November 14, 2005, 12:44:05 pm »
Quote from: "NeoLee"
The program I built needs a input file. But I do not know how to set the options in the IDE.
  Is it in the Evironment options or Debugging options ?
  And where to download a Chinese language pack?
 Thank you!


When you run your app from a cmdline, how would you give it the inputfile ?
//--
{$I stdsig.inc}
//-I still can't read someones mind
//-Bugs reported here will be forgotten. Use the bug tracker

 

TinyPortal © 2005-2018