Unexpected mail format

Hi All,I am sending the mail (rich text format) thorugh the notes client to the same user but at his two different id on the different servers, e.g one at “abcd@xxxx” and another at “wxyz@xxxx.com”.

At one id he is getting the mail in expected format(i.e. Rich Text Format) and on another as an unexpected fromat(Plain Text).

Plz share what may be the reason for that.The code written is as follows.

Sub Click(Source As Button)

   ' This routine sends an email message 



Dim session As New notessession

Dim w As New notesuiworkspace

Dim uidoc As notesuidocument

Dim doc As notesdocument

Dim db As notesdatabase

Dim EmailId As String

Dim rtitem2 As  Variant

Dim rtitem3 As Variant





Set uidoc = w.currentdocument

Set doc = uidoc.document	

If ( doc.IsNewNote ) Then

	Call doc.Save( True, False )

	Call uidoc.Refresh( True )

End If	

Set db = session.CurrentDatabase



EmailId = uidoc.FieldGetText("EmailTo")

'Check before proceeding

If EmailId = "" Then

	Messagebox "TO field must contain valid ids to send Email"

Else     

	If (Messagebox("Ok to send?", MB_OKCANCEL + MB_ICONQUESTION, "Sending Email")) = IDOK Then

'Create mail message

		Set newdoc = New notesdocument(db)    

		Set rtitem = New NotesRichTextItem(newdoc , "Body")

		Set rtitem2 = doc.GetFirstItem( "ApprovalEmail" )

		Set rtitem3 = doc.GetFirstItem( "AnotherRequest" )

		newdoc.Subject =  uidoc.FieldGetText("Apps") + " Install - " + uidoc.FieldGetText("Date1") 

		newdoc.Sendto = doc.EmailTo        

		newdoc.CopyTo = doc.CCTo			

		Call rtitem.AppendText( doc.EmailText(0) )

		Call rtitem.AddNewLine( 2 )

		Call rtitem.AppendText( "*************         Approval  Email(s)         ************************")

		Call rtitem.AddNewLine( 1 )

		Call rtitem.AppendRTItem ( rtitem2 )

		Call rtitem.AddNewLine( 2 )

		Call rtitem.AppendText( "*************             Another Request          ************************")

		Call rtitem.AddNewLine( 1 )

		Call rtitem.AppendRTItem ( rtitem3 )

		Call newdoc.Send(False)

	End If

End If

End Sub

Subject: Unexpected mail format

Check the MessageStorage field on the person docs. THey are probably set differently.

Subject: Unexpected mail format

Thanks for your response paul,The mail Message storage has already the format set as “Rich text”.

But it still displaying as plain text.

Subject: RE: Unexpected mail format

Let me guess (as you didn’t state this 100% clear):

When send to “abcd@xxxx” the message is received as rich text, when send to “wxyz@xxxx.com” it is plain text, right?

Sounds to me, that the mail addressed to the .com domain is routed out through some non-Domino server, that kicks out the formatting.

Subject: RE: Unexpected mail format

Thanks for your response harkpabst,

ok if that is the case, can u help me that what codes are to be included in my existing one, so that we can get the same format i.e, “Rich Text”?

Thanks in Advance

Subject: RE: Unexpected mail format

First you should make sure, that this is really the cause. You could try a mail trace to the Internet style mail address to see, if the mail is indeed routed through some server outside your domain. If so, the most intelligent solution would be to avoid this by proper network configuration.

If there is some sever not handling rich text correctly, it might still get away with a MIME formatted mail. You would have to look into the LotusScript MIME classes to see how to compose a message in that format.