×
Namespaces

Variants
Actions
Revision as of 09:49, 25 July 2012 by hamishwillee (Talk | contribs)

How to use RFileWriteStream

From Nokia Developer Wiki
Jump to: navigation, search

This article shows how to use RFileWriteStream to write a stream to a file.

Headers required:

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

Library needed:

LIBRARY estor.lib //RFileWriteStream 
LIBRARY efsrv.lib //RFs

Source:

TInt16 someInt;
RFileWriteStream writerStream;
 
// writerStream on cleanup stack
writerStream.PushL();
 
//fs is ur file session and fileName is name of ur file.
User::LeaveIfError(writerStream.Create(fs, fileName, EFileWrite));
 
writerStream.WriteInt16L(someInt);
writerStream.CommitL();
 
// free writerStream
writerStream.Pop();
writerStream.Release();

Related Links:

67 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×