Namespaces
Variants
Actions

Open file with its corresponding handler

Jump to: navigation, search
Article Metadata

Article
Created: giridharn (17 May 2007)
Last edited: hamishwillee (25 Jul 2012)
Reviewer Approved    Thumbs up icon sm.jpg

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);

This page was last modified on 25 July 2012, at 09:18.
62 page views in the last 30 days.
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved