dbaspot
Tags Register FAQ Calendar Search Today's Posts Mark Forums Read

Mail Size decreasing - lotus-notes-programmer

This is a discussion on Mail Size decreasing - lotus-notes-programmer ; Hi , Am trying to copy a mail from one nsf to another. Here i tried couple of methods like 1. CreateDocument(CurDoc, NewDoc); FolderAddDocument(NewDoc); 2. Getting each item of mail and creating that item in new mail of target nsf ...



Reply

 

LinkBack Thread Tools Display Modes
  #1  
Old 11-18-2008, 02:20 PM
Database Newbie
 
Join Date: Nov 2008
Posts: 1
umeshpaikk is on a distinguished road
Default Mail Size decreasing

Hi ,

Am trying to copy a mail from one nsf to another.
Here i tried couple of methods

like
1. CreateDocument(CurDoc, NewDoc);
FolderAddDocument(NewDoc);

2. Getting each item of mail and creating that item in new mail of target nsf
then move it to required folder.
Code:
entryDoc.Open();
entryDoc.ComputeWithForm(TRUE);
DestDb.CreateDocument(&newDocument);



entryDoc.GetItems(&Items);
LNINT NumItems = Items.GetCount();
newDocument.Open();
//newDocument.CreateItem("Body", &NewRT);


// Loop over the items.
for (LNINT i =0; i {

Item = Items[i];

// copy each item

CString str = Item.GetName();
LNString lnstr = Item.GetName();
LNITEMFLAGS flag = Item.GetFlags();
// fprintf(pFile1, " %s \n", str);

if ( Item.IsType(3) == TRUE )
{
continue;

}

// copy attachment
if ( Item.IsType(LNITEMTYPE_RICHTEXT) == TRUE )
{
newDocument.CreateItem("Body", &NewRT);
entryDoc.GetItem("Body", &RT);

NewRT.Append(RT);
newDocument.ComputeWithForm(TRUE);
newDocument.Save();


}

// copy other attribute of message
else
{

newDocument.CreateItem(lnstr,Item,LNITEMFLAGS_SUMM ARY,LNITEMOPTION_APPEND_ONLY,&newItem);
// newDocument.ComputeWithForm(TRUE);
Item.SetExpandOnSave(TRUE);
newDocument.Save();
// newItem.SetExpandOnSave(TRUE);
//newDocument.RefreshNoteHandleFromObject() ;

}

I also used LNRichText to copy mail body

In all the cases am loosing mail size on target nsf file.

Please let me know any one can help me out of this.
Please .....
Reply With Quote
Reply

Thread Tools
Display Modes



All times are GMT -4. The time now is 01:09 PM.