如何将公式转换为代理?我在视图中写了一个剩余天数公式,并希望使其成为代理。
公式:
FIELD DaysLeft := @If(ExpDate = ""; ""; @Integer((ExpDate - @Today)/60/60/24))
我在视图中有很多列,因此就像:
FIELD DaysLeft1 := @If(ExpDate1 = ""; ""; @Integer((ExpDate1 - @Today)/60/60/24))
FIELD DaysLeft2 := @If(ExpDate2 = ""; ""; @Integer((ExpDate2 - @Today)/60/60/24))
FIELD DaysLeft3 := @If(ExpDate3 = ""; ""; @Integer((ExpDate3 - @Today)/60/60/24))
保留默认选项:
声明:
Dim session As NotesSession
Dim db As NotesDatabase
Dim view As NotesView
初始化:
Sub Initialize
Dim doc As NotesDocument
Set session = New NotesSession
Set db = session.currentdatabase
FIELD DaysLeft := @If(ExpDate = ""; ""; @Integer((ExpDate - @Today)/60/60/24))
End Sub
这些对象的代码应该是什么?