Open file with its corresponding handler
Article Metadata
We can open a file with its corresponding handlers this way:
TDataType dataType;
// You can set this dataType to NULL ,to make framework select the
// corresponding handler for this file,depending on its MIME type.
CDocumentHandler* docHandler = CDocumentHandler::NewLC(iEikonEnv->Process());
// Here fileName can be of any file types, say .txt, .jpg etc., and not a
// user defined file types.
TFileName fileName;
fileName.Copy(_L("c:\\nokia\\images\\abc.jpg"));
docHandler->OpenFileL(fileName, dataType);
CleanupStack::PopAndDestroy(docHandler);


(no comments yet)