Lotus notes Lotus notes视图:检索上次打开的时间
上次打开视图时是否有方法/技巧? 在designer中,如果我右键单击某个视图,在“信息”选项卡中有一个参数“已访问”,我认为它与我正在查找的参数相对应。Lotus notes Lotus notes视图:检索上次打开的时间,lotus-notes,Lotus Notes,上次打开视图时是否有方法/技巧? 在designer中,如果我右键单击某个视图,在“信息”选项卡中有一个参数“已访问”,我认为它与我正在查找的参数相对应。 有一个技巧o方法可以检索该值?下面的代码将给出数据库中每个视图的“上次访问”日期和时间。请注意(根据帮助文件),此值的准确时间不超过24小时,就好像文档在24小时内被多次访问一样,上次访问的值不会更新 Dim db As NotesDatabase Dim s As New NotesSession Dim nc As NotesNoteCo
有一个技巧o方法可以检索该值?下面的代码将给出数据库中每个视图的“上次访问”日期和时间。请注意(根据帮助文件),此值的准确时间不超过24小时,就好像文档在24小时内被多次访问一样,上次访问的值不会更新
Dim db As NotesDatabase
Dim s As New NotesSession
Dim nc As NotesNoteCollection
Dim doc As NotesDocument
Dim ID As String
Dim title As string
Set db = s.Currentdatabase
Set nc = db.createNoteCollection(False)
nc.Selectviews = true
Call nc.Buildcollection()
id = nc.Getfirstnoteid()
While Not id = ""
Set doc = db.Getdocumentbyid(id)
title = doc.getitemvalue("$Title")(0)
Print title & ": " & doc.Lastaccessed
id = nc.Getnextnoteid(id)
Wend
要对一个特定视图执行相同操作,请执行以下操作:
Dim db As NotesDatabase
Dim s As New NotesSession
Dim nc As NotesNoteCollection
Dim doc As NotesDocument
Dim ID As String
Dim title As String
Dim view As NotesView
Set db = s.Currentdatabase
Set view = db.GetView("MyViewName")
Set nc = db.createNoteCollection(False)
Call nc.Add(view)
Call nc.Buildcollection()
id = nc.Getfirstnoteid()
While Not id = ""
Set doc = db.Getdocumentbyid(id)
title = doc.getitemvalue("$Title")(0)
Print title & ": " & doc.Lastaccessed
id = nc.Getnextnoteid(id)
Wend
下面的代码将给出数据库中每个视图的“上次访问”日期和时间。请注意(根据帮助文件),此值的准确时间不超过24小时,就好像文档在24小时内被多次访问一样,上次访问的值不会更新
Dim db As NotesDatabase
Dim s As New NotesSession
Dim nc As NotesNoteCollection
Dim doc As NotesDocument
Dim ID As String
Dim title As string
Set db = s.Currentdatabase
Set nc = db.createNoteCollection(False)
nc.Selectviews = true
Call nc.Buildcollection()
id = nc.Getfirstnoteid()
While Not id = ""
Set doc = db.Getdocumentbyid(id)
title = doc.getitemvalue("$Title")(0)
Print title & ": " & doc.Lastaccessed
id = nc.Getnextnoteid(id)
Wend
要对一个特定视图执行相同操作,请执行以下操作:
Dim db As NotesDatabase
Dim s As New NotesSession
Dim nc As NotesNoteCollection
Dim doc As NotesDocument
Dim ID As String
Dim title As String
Dim view As NotesView
Set db = s.Currentdatabase
Set view = db.GetView("MyViewName")
Set nc = db.createNoteCollection(False)
Call nc.Add(view)
Call nc.Buildcollection()
id = nc.Getfirstnoteid()
While Not id = ""
Set doc = db.Getdocumentbyid(id)
title = doc.getitemvalue("$Title")(0)
Print title & ": " & doc.Lastaccessed
id = nc.Getnextnoteid(id)
Wend