Question : lotus note create attachment function not showing proper application icon

hi i am using lotus note c plus plus api to create an attachment to a document note

the file is attached but the attached file is not having proper icon.
all attached file like doc,txt,xls all are having same icon.

what modification i have to do in my code to get the proper application icon of an attachment.
Code Snippet:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
LNNotesSession		Session;
	LNDatabase		Db;
	LNRichText		RT, NewRT;
	LNViewFolder 		Folder1, Folder2;
 
	DBHANDLE hdb = NULL;
	STATUS ret = Session.Init();
		
	Session.GetDatabase("C:\\MyRichText.nsf", &Db, "");
	Db.Open();
 
	Db.GetViewFolder("First", &Folder1);
	Db.CreateDocument(&NewDoc, MAIL_REPLY_FORM);
 
	NewDoc.Open( LNNOTEOPENFLAGS_DEFAULT );
	NewDoc.CreateItem("Body", &NewRT);
	NewRT.GetCursor(&rtCursor);
 
	NewRT.CreateAttachment("C:\\link1.txt",&rtCursor,"my text file",TRUE);
	NewRT.CreateAttachment("C:\\link1.doc",&rtCursor,"my doc file",TRUE);
	NewRT.CreateAttachment("C:\\link1.xls",&rtCursor,"my xls file",TRUE);
 
	NewDoc.Save();
	NewDoc.Close();
	Folder1.FolderAddDocument(NewDoc);
 
	Db.Close(); 
	Session.Term();

Answer : lotus note create attachment function not showing proper application icon

The Notes C++ API Version 3 might not be fully compatible with Notes release 6... Too difficult a question for me... Sorry.
Random Solutions  
 
programming4us programming4us