CsvBlockLoad

 

This function brings into the memory after reading a comma separated text file.

int @ CsvBlockLoad (string filename, int column, int row, int encoding);

 

Parameters

string filename: Read text file (to use the full file path)
int column: 10 Number of files to read
int row: Row number of the file to read
int encoding: String encoding (0 = ASCII, 1 = UTF8)


Return Value

If an error occurs during opening the file, it returns -1.

If it returns another numbers, it is the connection number.

Example

@DialogSetFilter ("Csv files | *. csv |");
retn = @ DialogFileOpen ($ filename);
if (retn == 1) (

@CsvBlockFree ($ID);
$ID = @CsvBlockLoad ($filename, 2, 50);
@CsvBlockSet ($ID, "ex.txt", 0);
$Number = 0;

)

Description: If you select the file in the File Open dialog box, it frees the previous block. And loads the file into the memory(Row 2, Column 50). Then tag is assigned to a value of the first row in ex.txt.

 

Relate items)

@CsvBlockDelete()

@CsvBlockFree()

@CsvBlockGet()

@CsvBlockGetText()

@CsvBlockInsert()

@CsvBlockLoad()

@CsvBlockNew()

@CsvBlockSave()

@CsvBlockSearchPos()

@CsvBlockSet()