参考这个问题,
我熟悉条件格式。但是我仍然面临这个问题。
我正在使用此代码将时间转换为以分钟为单位的时间。
Dim TestString As String
TestString = Me.Duration
Dim TestArray() As String
TestArray = Split(TestString, ":")
Dim Hours As String
Dim Minutes As String
Dim Seconds As String
Dim HoursMinutes As Integer
Dim MinutesMinutes As Integer
Dim SecondsMinutes As Integer
Hours = TestArray(0)
Minutes = TestArray(1)
Seconds = TestArray(2)
HoursMinutes = CInt(TestArray(0)) * 60
MinutesMinutes = CInt(TestArray(1))
SecondsMinutes = CInt(TestArray(2)) / 60
Dim TimeInMinutes As Integer
TimeInMinutes = HoursMinutes + MinutesMinutes + SecondsMinutes
Me.Duration = TimeInMinutes
但是,由于某种原因,这不起作用。
你有什么想法我怎样才能为单独的行做到这一点?
提前致谢
添加:
我尝试为 Minutes 创建一个字段,问题是它们将获得所有相同的数字。