Question: writting a file in another folder without using the whole directory adress

Hello,

 

I think the answer to my question is not there yet.

So I would like to save some variables in a .m file in an another folder without using the whole C:/.../ thing.

The reason why is that I am using a windows and a mac so if work on my mac I can still execute my reading and my writting commands on my mac.

 

the file I want to write from is located in :

/Maple_projet/Code/Timoshenko/

and the folder I want to write to is in

/Maple_projet/Code/Code_principal/

 

I thought of using currentdir() and then erasing the Timoshenko part to obtain:

/Maple_projet/Code/

 

and then join the "Code_principal/", but I dont know how to do that.

 

Any ideas?

 

Samy

Please Wait...