1、我有一个姓名列,列中有多个人名,输入时只能用“,”号分隔,怎么写代码控制?2、非自然月,我的统计月为日期型,要控制为“yyyy-MM”格式 下面的代码怎么改?
Select
Case e.DataCol.name
Case
"日期"
If e.NewValue Is
Nothing
Then
e.DataRow("统计月") = Nothing
Else
Dim dt As
Date = e.NewValue
If dt.Day > 25
Then '如果为25日以后的日期
dt = new Date(dt.year,dt.month,1) '改为下个月的第一天
dt= dt.AddMonths(1)
End
If
e.DataRow("统计月") =Format(dt,"yyyy-MM")'这个格式改了后还是"yyyy-MM-01",列的日期格式没有yyyy-MM,只能改成字符型的吗?
End
If
End
Select
[此贴子已经被作者于2016/9/21 0:57:05编辑过]