惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Microsoft Azure Blog
Microsoft Azure Blog
WordPress大学
WordPress大学
Google DeepMind News
Google DeepMind News
美团技术团队
大猫的无限游戏
大猫的无限游戏
H
Help Net Security
小众软件
小众软件
aimingoo的专栏
aimingoo的专栏
博客园 - 聂微东
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
M
MIT News - Artificial intelligence
酷 壳 – CoolShell
酷 壳 – CoolShell
博客园 - Franky
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
Microsoft Security Blog
Microsoft Security Blog
F
Fortinet All Blogs
A
About on SuperTechFans
Recent Announcements
Recent Announcements
D
Docker
Vercel News
Vercel News
Engineering at Meta
Engineering at Meta
腾讯CDC
Martin Fowler
Martin Fowler
阮一峰的网络日志
阮一峰的网络日志

博客园 - an_andy

MOSS 2007定制开发培训 Soft Skill MOSS 2007: Implementing a custom Navigation MOSS2007 - Microsoft Release sample Master Pages Customizing the Quick Launch menu: Adding fly-out menus to SharePoint navigation 招聘SharePoint Developer Office System 2007 update Office 2007 Beta2 Downloads WinFX SharePoint Search 文档管理[权限] Enterprise Library SQL Server Reporting Services 从应用程序生成用户友好的报表 Live Communications Server 2005 sp1 发布 Portal 个性登录页 显示wss图片库:速度 基于sharepoint 2003的内容管理1.0 Single Sing-On 单点登录 Visual Studio Tools For Office "v3" - March Community Technology Preview [CTP]
GetUserProfilerWebPart 设计文档
an_andy · 2006-05-09 · via 博客园 - an_andy

功能描述:
按照不同的数据源显示sps用户配置文件信息,具有查询,筛选,排序,分页等功能,以webpart形式封装;
应用场景:
用于企业内部黄页,person site,结合office客户端进行多种方式通信,outlook,windows messenger在线提醒;
开发环境:
Windows server 2003
windows sharepoint services 2.0
sharepoint portal server 2003
visual studio.net 2003

数据源: 
1 网站loginName集合[default]
SPSite siteCollection = SPControl.GetContextSite(Context);
SPWeb site = siteCollection.RootWeb;
SPUserCollection users = site.AllUsers;
foreach (SPUser user in users)
{
 user.LoginName;//LoginName集
}
 


2 AD的loginName集合
--截取domainName值
--int intStart = this.LDAPAddress.IndexOf("DC=");
--string strFirstDC = this.LDAPAddress.Substring(intStart+3);
--int intEnd = strFirstDC.IndexOf(",");
--string domainName = strFirstDC.Substring(0,intEnd);
DirectoryEntry myEntry = new DirectoryEnty (LDAPAddress,AdministratorName,AdministratorPwd,AuthenticationTypes.Secure);
DirectorySearcher mySearcher = new DirectorySearcher(myEntry);
mySearcher.SearchScope = SearchScope.OneLevel;
mySearcher.Filter = "(objectClass=user)";
SearchResultCollection myResultCollection = mySearcher.FindAll();
foreach(SearchResult myResult in myResultCollection)
{
 DirectoryEntry userEntry = new DirectoryEntry(myResult.Path,AdministratorName,AdministratorPwd,AuthenticationTypes.Secure);
string userName = userEntry.Properties["samAccountName"].Value.ToString();
 domainName +"\\"+ userName; //LoginName集
}

配置信息:
1 LDAPAddress        //LDAP查询串(LDAP://CN=”department”,DC=”domain”,DC=”com”)
2 AdministratorName  //域管理员帐号
3 AdministratorPwd   //域管理员密码
4 ShowName           //自定义配置文件的显示名称,default为姓名,手机,工作电子邮件地址,部门
5 MyQuery            //筛选条件
6 Query2             //筛选值(>;>=;<;<=;=)
7 DispOder           //在用户配置文件中增加配置文件属性“显示顺序”,用于排序

前台显示问题:
因为涉及很多html代码及样式,我想每个开发人员都不想陷入到与客户的变幻无常的界面,样式的修改,调整里;
所以暂时决定采用静态置标[$姓名$]的方式,让客户去维护类似的html页;鉴于此举,想征询各位同仁的高招,感谢!!!