|
1 <?xml version="1.0" encoding="utf-8"?> |
|
2 <!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. --> |
|
3 <!-- This component and the accompanying materials are made available under the terms of the License |
|
4 "Eclipse Public License v1.0" which accompanies this distribution, |
|
5 and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". --> |
|
6 <!-- Initial Contributors: |
|
7 Nokia Corporation - initial contribution. |
|
8 Contributors: |
|
9 --> |
|
10 <!DOCTYPE task |
|
11 PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd"> |
|
12 <task id="GUID-1B363B7B-35E9-5CD9-BC44-A19D94DA1D21" xml:lang="en"><title>Removing |
|
13 attachments from messages</title><shortdesc>The messaging framework allows you to remove attachments from messages. </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody> |
|
14 <context id="GUID-E21AD703-A9AA-5153-B0EE-D068D6295257"><p>Attachments to |
|
15 a message may be removed. </p> </context> |
|
16 <steps id="GUID-F9F2F6BC-DC86-5931-BA0F-9E20212640ED"> |
|
17 <step id="GUID-38716981-EE99-52C2-9522-082D188776C9"><cmd>Get the details |
|
18 of the message to which you want to add an attachment using <xref href="GUID-85BBE389-81F7-3E2F-A789-446D9BE2CC49.dita#GUID-85BBE389-81F7-3E2F-A789-446D9BE2CC49/GUID-1864B96D-CB22-3EE1-8E73-023F12C68CB0"><apiname>CMsvEntry::EditStoreL()</apiname></xref>. </cmd> |
|
19 <info>This function returns <xref href="GUID-8CB90FA2-A6CF-3FA2-81FF-7D22EFD9C2CE.dita"><apiname>CMsvStore</apiname></xref> in writable mode. </info> |
|
20 </step> |
|
21 <step id="GUID-98B33831-888B-5354-80B6-9628C32F05C8"><cmd>Get an <xref href="GUID-4E2B0CEA-1EDA-3452-895D-3CE1B59FD8FD.dita"><apiname>MMsvAttachmentManager</apiname></xref> attachment |
|
22 manager for the message entry, using <xref href="GUID-8CB90FA2-A6CF-3FA2-81FF-7D22EFD9C2CE.dita#GUID-8CB90FA2-A6CF-3FA2-81FF-7D22EFD9C2CE/GUID-73CE27F3-855B-3F87-AE11-4B4F2B8F8825"><apiname>CMsvStore::AttachmentManagerL()</apiname></xref>. </cmd> |
|
23 </step> |
|
24 <step id="GUID-DCE18F1F-1314-581E-A6A9-06EFF8FF102D"><cmd/> |
|
25 <info>Remove an attachment using the <xref href="GUID-4E2B0CEA-1EDA-3452-895D-3CE1B59FD8FD.dita#GUID-4E2B0CEA-1EDA-3452-895D-3CE1B59FD8FD/GUID-3BD2E3BF-AD83-3BFA-9C8D-D823F4F9D71E"><apiname>MMsvAttachmentManager::RemoveAttachmentL()</apiname></xref> function. </info> |
|
26 <stepxmp><codeblock id="GUID-A70E9B23-6962-5347-8C4A-D79E7CD514E6" xml:space="preserve">void CFoo::RemoveAttachL(TInt aNum) |
|
27 { |
|
28 ... |
|
29 |
|
30 TRequestStatus status; |
|
31 |
|
32 // Remove attachment with index aNum |
|
33 attManager.RemoveAttachmentL(aNum, status); |
|
34 |
|
35 // Wait for request to complete |
|
36 User::WaitForRequest(status); |
|
37 |
|
38 ... |
|
39 }</codeblock> </stepxmp> |
|
40 </step> |
|
41 </steps> |
|
42 </taskbody><related-links> |
|
43 <link href="GUID-1963A487-D6A7-4225-8D0C-EC5FAB746854.dita"><linktext>Attachment |
|
44 Tutorial</linktext></link> |
|
45 <link href="GUID-54AB166A-8B24-5065-92AD-5FC1BF3ED89C.dita"><linktext>Messaging |
|
46 Framework Overview</linktext></link> |
|
47 </related-links></task> |