SmartGWT - 以yyyy / MM / dd格式显示日期

时间:2011-01-20 12:47:25

标签: date smartgwt

我希望有可能显示一个可以手动输入日期的日期。 为此,我使用设置为useTextField的属性true,如:

setAttribute("useTextField", true);

现在我希望date的格式为yyyy / MM / dd。

我尝试过

setAttribute("displayFormat ", "TOJAPANSHORTDATE");
setAttribute("inputFormat ", "YMD");

但没有任何事情发生。

我需要使用属性。 我应该使用什么属性?具有什么价值?

请,需要帮助。 非常感谢你。

1 个答案:

答案 0 :(得分:1)

你可以尝试

.setDisplayFormat(DateDisplayFormat.TOJAPANSHORTDATE);
相关问题