您的位置:首页 > 编程语言 > MATLAB

matlab GUI 实现文件夹选择

2016-04-08 08:54 501 查看
matlab实现多个文件夹选择

单个文件夹选择

Open folder selection dialog box

使用

uigetdir

folder_name = uigetdir

folder_name = uigetdir(start_path)

folder_name = uigetdir(start_path,dialog_title)


Description

folder_name = uigetdir
displaysa modal dialog box showing the folders that are inside the currentworking directory. This dialog allows you to navigate to a folderand select it (or
type the name of a folder). If the folder you specifyexists,
uigetdir
returns the selected path whenyou click
OK. If you click Cancel (orthe window's close box),
uigetdir
returns
0
.

folder_name = uigetdir(start_path)
showsthe folders that are inside the folder,
start_path
.If
start_path
is an empty string (
''
)or is not a valid path, the dialog box opens in the current workingdirectory.

folder_name = uigetdir(start_path,dialog_title)
opensa dialog box with the title,
dialog_title
. Thedefault
dialog_title
is Select Directoryto Open.

Note: The visual characteristics of the dialog box depend on the operatingsystem that runs your code. For instance, some operating systems donot show title bars on dialog boxes. If you pass a dialog box titleto the uigetdir function, those
operating systems will not displaythe title.





获取文件

uigetfile

保存文件

uiputfile

保存变量到文件

uisave

Open dialog box for saving variables to MAT-file
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: