GetTopLineTXTFile

From scripting
Revision as of 06:02, 22 April 2017 by Nickpisca (talk | contribs) (Created page with " int $YYY = GetTopLineTXTFile("c:\\mayacount.txt"); global proc int GetTopLineTXTFile(string $Path) { //Nick Pisca 0001d, string $Path = "c:\\mayacount.txt"; string...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
int $YYY = GetTopLineTXTFile("c:\\mayacount.txt");

global proc int GetTopLineTXTFile(string $Path) {
 	//Nick Pisca 0001d, string $Path = "c:\\mayacount.txt";
  	string $exampleFileName = ( $Path );
  	string $s;
 	$fileId=`fopen $exampleFileName "r"`;
	$s=`fread $fileId $s`;
 	fclose $fileId;
	return $s;
}



Related Functions: ChangeTopLineTXTFile

More information on strings and naming, read pages 28-37 in YSYT.