简体   繁体   English

使用Powershell查找Lotus Notes Internet电子邮件地址

[英]Using Powershell to find Lotus Notes internet email address

Using Powershell, I need to retrieve an Internet email address from a Lotus Notes names.nsf address book. 使用Powershell,我需要从Lotus Notes names.nsf地址簿中检索Internet电子邮件地址。

Within Notes, I can see the internet email address I want to retrieve. 在Notes中,我可以看到我想要检索的互联网电子邮件地址。 It is on the Basics tab, under the Mail section, in a field called "Internet Address". 它位于“基本”选项卡上的“邮件”部分的“Internet地址”字段中。 However, I have not been able to find the view it is under, or a way to query it or derive it. 但是,我无法找到它所处的视图,或查询它或派生它的方法。 It would also be helpful to filter the email addresses I would like to find by the Company on the "Work/Home" tab in Lotus Notes. 在Lotus Notes的“工作/主页”选项卡上过滤公司希望查找的电子邮件地址也很有帮助。

Opening one of the names.nsf files in IE, I see a number of the fields I want, but a formatted internet email address isn't in there. 在IE中打开其中一个names.nsf文件,我看到了我想要的一些字段,但格式化的互联网电子邮件地址不在那里。 All I see is the Lotus notes style of email address: 我只看到Lotus笔记的电子邮件地址样式:

firstname lastname/mycompany/abc @ abc firstname lastname / mycompany / abc @ abc

(The column name that is in is named $16 ). (列中的列名称为$ 16 )。

Is there a way to pull the full internet email addresses from a Lotus Notes names.nsf address book? 有没有办法从Lotus Notes names.nsf地址簿中提取完整的互联网电子邮件地址? If so, how? 如果是这样,怎么样? If they are in some of the "hidden" views available, how do you query the values in those hidden views? 如果它们处于某些可用的“隐藏”视图中,您如何查询这些隐藏视图中的值?

Thanks! 谢谢!

In many cases, the best view to use for finding Person documents is the hidden view called "$Users". 在许多情况下,用于查找Person文档的最佳视图是名为“$ Users”的隐藏视图。 It is indexed by just about every variation of the name that you can think of, so lookups just tend to work. 它几乎被您能想到的名称的每个变体编入索引,因此查找只是起作用。 You can find it by opening the Person document from the view and reading the NotesItem named "InternetAddress", or you can read it directly from the view column that is labled "InternetAddress", which I believe is the 17th column. 您可以通过从视图中打开Person文档并读取名为“InternetAddress”的NotesItem来查找它,或者您可以直接从标有“InternetAddress”的视图列中读取它,我相信这是第17列。

You can access all of the properties for a given user from the NAB using powershell. 您可以使用powershell从NAB访问给定用户的所有属性。 You must run the 32 bit version of PS if your Notes client is 32 bit. 如果Notes客户端是32位,则必须运行32位版本的PS。 You will be prompted for your Notes ID password. 系统将提示您输入Notes标识密码。

  $notes=new-object -comobject Lotus.NotesSession;
  $notes.Initialize("");
  $ndb = $notes.getdatabase("admin","names.nsf");
  $nview = $ndb.getview('($Users)');
  $searchkey = "Schmoe"; #whatever
  $doc =$nview.getdocumentbykey($searchkey,$true);
  $mailaddress = $doc.getitemvalue('mailaddress')[0];
  $internetaddress = $doc.getitemvalue('internetaddress')[0];

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM