How would I connect to the Domino Object library, equivalent to VBA's Tools/References/Lotus Domino Objects?
How would I connect to the Domino Object library, equivalent to VBA's Tools/References/Lotus Domino Objects?
sluice wrote:From this:
> How would I connect to the Domino Object library, equivalent to VBA's
> Tools/References/Lotus Domino Objects?
>
>
http://www.ibm.com/developerworks/lo...ls-COM_Access/
I would infer:
$notes=new-object -comobject Lotus.NotesSession
Now, $notes would be the object to work with.
--
Microsoft MVP - Windows PowerShell
http://www.microsoft.com/mvp
PowerGadgets MVP
http://www.powergadgets.com/mvp
Blog:
http://marcoshaw.blogspot.com
Marco Shaw [MVP] wrote:I can confirm this works, not that I can figure out what to do with the
> I would infer:
> $notes=new-object -comobject Lotus.NotesSession
resulting object.
--
Hal Rottenberg
Blog: http://halr9000.com
Webmaster, Psi (http://psi-im.org)
Co-host, PowerScripting Podcast (http://powerscripting.net)
The next thing to do would be
$notes.initialize("password") #This would open a session
Next is define the path to your .nsf file and open that, then it gets more complicated. I'm working on it.
sluice wrote:Let us know how it goes, I'm interested in your results if nobody else is.
> The next thing to do would be
> $notes.initialize("password") #This would open a session
>
> Next is define the path to your .nsf file and open that, then it gets
> more complicated. I'm working on it.
--
Hal Rottenberg
Blog: http://halr9000.com
Webmaster, Psi (http://psi-im.org)
Co-host, PowerScripting Podcast (http://powerscripting.net)
I'm still struggling with it, and have got as far as:
$notes=new-object -comobject Lotus.NotesSession
$notes.Initialize("password")
$ssgtech=$notes.GetDatabase("server","ssgtech.nsf")
$ssgtech.open(??)
I'm stuck on how to get it to open the database.
$ssgtech.open gives me:
PS C:\Documents and Settings\Simon Lucas> $ssgtech.Open
MemberType : Method
OverloadDefinitions : {void Open ()}
TypeNameOfValue : System.Management.Automation.PSMethod
Value : void Open ()
Name : Open
IsInstance : True
but in my general state of ignorance, I don't know what the parameters should be to open the database.
I have found that the way to open the database should be:
$ssgtech=$notes.GetDatabase("server","ssgtech.nsf",1)
$mydoc=$ssgtech.GetDocumentByID(""S1003090")
I think!
Try calling open like this: "open()".
> PS C:\Documents and Settings\Simon Lucas> $ssgtech.Open
>
>
> MemberType : Method
> OverloadDefinitions : {void Open ()}
> TypeNameOfValue : System.Management.Automation.PSMethod
> Value : void Open ()
> Name : Open
> IsInstance : True
>
> but in my general state of ignorance, I don't know what the parameters
> should be to open the database.
I tried it but it failed. Unfortunately my great idea in post 7 also failed. I tried
$ssgtech.isopen|write-host
which returned False.
PS C:\Documents and Settings\> $ssgtech.open()
Exception calling "Open" with "0" argument(s): "Database open failed (server!!ssgtech.nsf)"
At line:1 char:14
+ $ssgtech.open( <<<< )
PS C:\Documents and Settings\> $mydoc=$ssgtech.GetDocumentByID("S1003090")
Exception calling "GetDocumentByID" with "1" argument(s): "Database server!!ssgtech.nsf has not been opened yet"
At line:1 char:32
+ $mydoc=$ssgtech.GetDocumentByID( <<<< "S1003090")
| Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Send a mail through a lotus domino server using powershell | Pako Nukem | PowerShell | 0 | 23 Jan 2009 |
| acquiring machine name from inside an object library | jason | .NET General | 2 | 13 Nov 2008 |
| Any known fixes for problems using email with Lotus Domino Web Acc | Dimitris | Vista General | 2 | 27 Jun 2008 |
| Microsoft Speech Object Library compiler warnings | Kevin S Gallagher | .NET General | 0 | 21 May 2008 |
| Software products in Windows Vista won't open Lotus Domino Web Acc | michboyd1 | Vista installation & setup | 1 | 22 Apr 2008 |