gui的MATLAB日期选择弹出日历 [英] MATLAB date selection popup calendar for gui

查看:1394
本文介绍了gui的MATLAB日期选择弹出日历的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有人知道在MATLAB中显示弹出日期选择日历的方法?我知道金融工具箱有一个 uicalendar 函数,但不幸的是我没有那个工具箱。



我有一个希望我将不得不使用一些Java或其他一些语言,我不知道什么。



我正在寻找类似的东西:
alt text http://www.welie.com/patterns/images /date-selector-expedia-small.png



这将在用户选择日期后返回日期字符串。

解决方案

不幸的是,我没有太多时间获得更完整的答案,但我会尝试可用创建一个表并定义 CellSelectionCallback 来获取日期。



这有一点让你开始:

  dates = calendar; 
日期(〜any(dates,2),:) = [];
fh = figure;
uh = uitable('parent',fh,'data',dates,'ColumnWidth',repmat({20},1,7),...
'ColumnName',{'S' ,'M','T','W','T','F','S'})


Does anyone know of a method to display a popup date selection calendar in a MATLAB gui? I know the financial toolbox has a uicalendar function, but unfortunately I don't have that toolbox.

I have a hunch I'm going to have to use some Java or some other language for this one, which I know nothing about.

I'm looking for something similar to this: alt text http://www.welie.com/patterns/images/date-selector-expedia-small.png

which would return a date string after the user selects the date.

解决方案

I don't have much time for a more complete answer, unfortunately, but I'd try uitable to create a table and to define the CellSelectionCallback to get the date.

Here's a bit to get you started:

dates = calendar;
dates(~any(dates,2),:) = [];
fh = figure;
uh = uitable('parent',fh,'data',dates,'ColumnWidth',repmat({20},1,7),...
             'ColumnName',{'S','M','T','W','T','F','S'});

这篇关于gui的MATLAB日期选择弹出日历的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆