Matlab: String variables to fopen()

1 reply · 5K views · last reply
Eren10
Messages
17
Reaction score
0
HI

can't I pass the path of a file as a string variable to fopen() , like this:

path = 'aadada'

fopen(path)

I want to do create many files, the paths have a logic, so I can put them in cell array and than I want to pass them to fopen() , but fopen doesn't accept a string variable, this is strange.
 
problem solved, just use char() to make characters of path