Borrar filtros
Borrar filtros

I wanna save string data in my gui with txt format but I want to choose directory and file name in dialog box

1 visualización (últimos 30 días)
for example;
string=[100, 150, 200]
I want to save this data with .txt format in dialog box which enables me to choose directory and file name like uiputfile.

Respuesta aceptada

David Sanchez
David Sanchez el 22 de Mayo de 2013
[file_name PathName] = uigetfile('*.mat','Select *.mat file');
full_file_path = fullfile(PathName, file_name);
fid = fopen('my_txt_file.txt','w'); % open file for writting
fwrite(fid,full_file_path);
fclose(fid);
  1 comentario
sermet
sermet el 22 de Mayo de 2013
[file_name PathName] = uigetfile('*.mat','Select *.mat file'); in here, which .mat files I have to choose, I don't have any .mat files, I wanna save my string data in GUI.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Low-Level File I/O en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by