Namespaces
Variants
Actions

How to use RFileReadStream

Jump to: navigation, search
Article Metadata

Compatibility
Platform(s): All

Article
Created: savaj (07 Mar 2009)
Last edited: hamishwillee (04 Dec 2012)

This article shows how to use RFileReadStream to read a stream from file.

Headers required:

#include <s32file.h> //RFileReadStream
#include <f32file.h> //RFs

Library needed:

LIBRARY estor.lib //RFileReadStream
LIBRARY efsrv.lib //RFs

Source:

TInt16 someInt;
RFileReadStream streamReader;
 
// streamReader on cleanup stack
streamReader.PushL();
 
// fs is your file session and fileName is name of your file.
User::LeaveIfError(streamReader.Open(fs, fileName, EFileRead));
 
// read it
someInt = streamReader.ReadInt16L();
 
 
// free streamReader
CleanupStack::PopAndDestroy();

Related Links:

This page was last modified on 4 December 2012, at 02:50.
120 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