# MATLAB: How to supply string inputs to the program from a textfile

read inputs from textfilestring inputstext inputs

I have a program called run_from_cla.m that accepts the absolute path (i.e. a string) of the dataset directory as the input. The syntax to run the program is as follows:
run_from_cla('E:\data_analysis\09mar2015');
What I need is to generate a .txt file called datasetpaths.txt, which will have contents as follows:
E:\data_analysis\09mar2015E:\data_analysis\12mar2015E:\data_analysis\08mar2015E:\data_analysis\01mar2015E:\data_analysis\11mar2015
The requirement is to read the paths line-by-line from this textfile until the end of file and in each step pass on the path string to the program run_from_cla.m as a command line argument. This should run in a while loop (upto the end of file). Any solution ?

fid = fopen('fgetl.m');tline = fgetl(fid);while ischar(tline)    disp(tline)    tline = fgetl(fid);endfclose(fid);