首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 企业软件 > 行业软件 >

怎么用代理增加视图列

2012-02-29 
如何用代理增加视图列想用代理给一个视图增加一列,要怎么写?[解决办法]用notesview类的CreateColumn方法。

如何用代理增加视图列
想用代理给一个视图增加一列,要怎么写?

[解决办法]
用notesview类的CreateColumn方法。帮助里面有例子的
This agent creates a new column at the end of the "By Category" view based on the Subject2 field.
Sub Initialize
Dim s As New NotesSession
Dim col As NotesViewColumn
Set view = s.CurrentDatabase.GetView("By Category")
Set col = view.CreateColumn(view.ColumnCount + 1, _
"Topic 2", _
"Subject2")
Messagebox "Position: " & col.Position & Chr(13) & _
"Title: " & col.Title & Chr(13) & _
"Formula: " & col.Formula,, "New column added"
End Sub

热点排行