DocLink'ing a document in the mail db with document in another db w/lotusScript

DocLink'ing a document in the mail db with document in another db w/lotusScript

Post by lockhart.raleigh.ibm.co » Thu, 26 Sep 1996 04:00:00



Help ... help ... help ...                                              

I'm trying to create a doclink linking a piece of mail in my mail db to
a document stored on a local db.  End result will be that the user looks
at a document in the database HotLineD, that will contain a Doclink to  
document in the mail db.                                                

I run an agent that runs the following script :                        

Sub Initialize                                                          
   'set up for document in my mail db                                  
     Dim session As New NotesSession                                    
     Dim db As NotesDatabase                                            
     Set db = session.CurrentDatabase                                  
     Dim dc As NotesDocumentCollection                                  
     Dim doc As NotesDocument                                          
     Set dc = db.AllDocuments                                          
     Set doc = dc.GetFirstDocument()                                    
     Messagebox "Universal ID: " & doc.UniversalID                      
   'set up for document in the HotLineD database                        
   '                                                                    
     Dim db1 As NotesDatabase                                            
     Set db1 = session.GetDatabase( "", "HotLineD.nsf" )                  
     Dim doc1 As NotesDocument                                            
     Set doc1 = db1.GetDocumentByUNID( "FADA238EB3DDD008852563AE00668966")
     Set rtitem = New NotesRichTextItem( doc1, "Linkhere")                
     Call rtitem.AppendDocLink(doc, db.Title)                            
     Call doc1.Save( False, True )                                        
End Sub                                                                  

I'm able to find the document in HotLineD and able to append something    
to it, but no DocLink icon shows up. I say "append something" because if  
I check the field properties for the HotLineD document, I see the field  
"Linkhere" twice -                                                        

it's listed first as :                                                    

   Field Name: Linkhere                                                  
   Data Type: Rich Text                                                  
   Data Length: 68 bytes                                                  
   Seq Num: 8                                                            
   Dup Item ID: 2                                                    
   Field Flags: SIGN SEAL                                            

and then again as :                                                  
   Field Name: Linkhere                                              
   Data Type: Rich Text                                              
   Data Length: 0 bytes                                              
   Seq Num: 8                                                        
   Dup Item ID: 1                                                    
   Field Flags:                                                      

The document appears to be unchanged.  What am I doing wrong ?  Am I
expecting more than what Notes can supply ?  I'd like to create a    
doclink with LotusScript in the same manner as Notes does it with    
"Copy as Link" and paste.                                            

Does anyone know what the "Field Flags: SIGN SEAL" is ?  Any thoughts
why it is appearing twice ?                                          

Thanks for any help ... I'm going nuts here ...                      

 
 
 

DocLink'ing a document in the mail db with document in another db w/lotusScript

Post by lockhart.raleigh.ibm.co » Thu, 26 Sep 1996 04:00:00


Help ... help ... help ...                                              

I'm trying to create a doclink linking a piece of mail in my mail db to
a document stored on a local db.  End result will be that the user looks
at a document in the database HotLineD, that will contain a Doclink to  
document in the mail db.                                                

I run an agent that runs the following script :                        

Sub Initialize                                                          
   'set up for document in my mail db                                  
     Dim session As New NotesSession                                    
     Dim db As NotesDatabase                                            
     Set db = session.CurrentDatabase                                  
     Dim dc As NotesDocumentCollection                                  
     Dim doc As NotesDocument                                          
     Set dc = db.AllDocuments                                          
     Set doc = dc.GetFirstDocument()                                    
     Messagebox "Universal ID: " & doc.UniversalID                      
   'set up for document in the HotLineD database                        
   '                                                                    
     Dim db1 As NotesDatabase                                            
     Set db1 = session.GetDatabase( "", "HotLineD.nsf" )                  
     Dim doc1 As NotesDocument                                            
     Set doc1 = db1.GetDocumentByUNID( "FADA238EB3DDD008852563AE00668966")
     Set rtitem = New NotesRichTextItem( doc1, "Linkhere")                
     Call rtitem.AppendDocLink(doc, db.Title)                            
     Call doc1.Save( False, True )                                        
End Sub                                                                  

I'm able to find the document in HotLineD and able to append something    
to it, but no DocLink icon shows up. I say "append something" because if  
I check the field properties for the HotLineD document, I see the field  
"Linkhere" twice -                                                        

it's listed first as :                                                    

   Field Name: Linkhere                                                  
   Data Type: Rich Text                                                  
   Data Length: 68 bytes                                                  
   Seq Num: 8                                                            
   Dup Item ID: 2                                                    
   Field Flags: SIGN SEAL                                            

and then again as :                                                  
   Field Name: Linkhere                                              
   Data Type: Rich Text                                              
   Data Length: 0 bytes                                              
   Seq Num: 8                                                        
   Dup Item ID: 1                                                    
   Field Flags:                                                      

The document appears to be unchanged.  What am I doing wrong ?  Am I
expecting more than what Notes can supply ?  I'd like to create a    
doclink with LotusScript in the same manner as Notes does it with    
"Copy as Link" and paste.                                            

Does anyone know what the "Field Flags: SIGN SEAL" is ?  Any thoughts
why it is appearing twice ?                                          

Thanks for any help ... I'm going nuts here ...                      

 
 
 

1. synchronizing Notes Mail DB and CC Mail DB in 2 environments

Hi,

Id like to write code to change a cc:Mail users password on a post office
on a netware server. id like to initiate this process from an AIX box
however.

My thoughts were this:

Run a Notes Mail Server on the AIX box, and.. IF (this is my question) it
is possible
to synchronize user databases, I could simply.. initially inherit the users
from the cc:Mail post office, and when ever a change needs to be made to a
user on the cc:Mail side, I would simply use the Notes API to make a change
to the Notes Mail DB (to that particular user). The new Notes Mail DB would
then propogate itself over to the cc:Mail post office.

I havent used Notes very much, not developed using its API,  but if

1. auto synchronization is possible, and
2. the Notes API allows one to change a password...

Then I should be set, is this right???

Any comments would be most appreciated!

Thanks in advance,
Akil

2. How to use "find" in Oracle Book 2.1 ?

3. Don't want DB icon added when click on DocLink

4. Duplicate Email Delivery

5. OLE'ing an Adobe Acrobat document

6. Command Line Compiling Using .sln and .csproj Files

7. Users entering DB via Doclink see everything -- entering via Bookmark and everything's normal

8. IBM may make bid to buy Lotus.

9. Does Notes log web log-ins?

10. Calendar Templates or Plug-ins

11. I make Add-Ins for Lotus Organizer 6.0

12. Word-like plug-ins for Notes

13. Add ins?