Please note that as of October 24, 2014, the Nokia Developer Wiki will no longer be accepting user contributions, including new entries, edits and comments, as we begin transitioning to our new home, in the Windows Phone Development Wiki. We plan to move over the majority of the existing entries over the next few weeks. Thanks for all your past and future contributions.
If you want to give your users the ability to enter bigger amount of text then you can use CNotepadApi.
NB! The editor of this class has Find menu item under Options. If you don't have ReadDeviceData and WriteDeviceData capabilities set, then your app will panic with KERN-EXEC 0 when selecting this menu item.
Linking and header required:
link against: NpdLib.lib
header required: #include <npdapi.h>
TRAPD(err,buf=CNotepadApi::ExecTextEditorL(aReturnStatus,iText,_L("Edit Text"),_L("Delete txt?")));
if(aReturnStatus==3007 || aReturnStatus==KErrNone)
buf = NULL;
Following is the code to fetch template using CNotepadeApi
CNotepadApi * pNotePad = CNotepadApi:: NewLC ();
HBufC* pTemplate = NULL;
pTemplate = pNotePad->FetchTemplateL();
//copy pTemplate into a buffer and can use in your application.