Portal Engine Questions on portal engine and web parts.
Version 5.x > Portal Engine > Question about attachements View modes: 
User avatar
Member
Member
andrew-romanenco - 2/5/2010 3:59:01 PM
   
Question about attachements
Hello

I have question about document attachments, steps:

1. Create new document with field Files, type: DocumentAttachements
2. As expected all forms (including users contribution) show attachments management block and users can add multiple files, reorder them or delete
3. Now we need to list all document and all with all attachments, for example

---------------
Doc1 title
File1, File2, File3

Doc2 title
File1, File2, File3

and so on
------------

I have added Datalist webpart from Listings&Viewers and see all documents, but without attachments

So the question is how to show these attachments for EACH document in list (not for current one).
As suppose I should modify Transformation, but I can not find example in docs

Thank you

User avatar
Kentico Support
Kentico Support
kentico_jurajo - 2/8/2010 4:20:56 AM
   
RE:Question about attachements
Hi,

Could you please try to follow this description about Grouped attachments?

I hope it will help.

Best Regards,
Juraj Ondrus

User avatar
Member
Member
andrew-romanenco - 2/8/2010 1:56:45 PM
   
RE:Question about attachements
yes, I saw this document, it is very useful

but the question is how to show Grouped Attachments with transformation:

you have example transofmation with code:
<cms:DocumentAttachments ID="ucDocAttachments" runat="server" TransformationName="cms.root.attachment" Path='<%# Eval("NodeAliasPath") %>' />

this works perfect for unsorted attachs

Could you post the same code for Grouped Attachments, to use it in my custom transformation ?

Thank you

User avatar
Member
Member
andrew-romanenco - 2/8/2010 2:20:03 PM
   
RE:Question about attachements
Adding:

AttachmentGroupGUID="FieldName" solves problem

Anyway, thanks
;)

User avatar
Member
Member
ramyadav_ry-yahoo - 6/11/2010 6:48:06 AM
   
RE:Question about attachements
Can u give me provide me 1 example , how to use DocumentHelper.AddGroupedAttachment method with API.

User avatar
Member
Member
ramyadav_ry-yahoo - 6/11/2010 6:59:40 AM
   
RE:Question about attachements
I need Code sample to find out AttachmentGroupGUID for a perticular node at the time of adding new node.

Actually i am adding Article from API and i want to add Group Attachment through API.

can u help me to get current node AttachmentGroupGUID .

User avatar
Kentico Consulting
Kentico Consulting
kentico_borisp - 6/11/2010 9:20:49 AM
   
RE:Question about attachements
Hello,

The AttachmentGroupGUID is the GroupGUID of the group the attachment belongs to.
The GroupGUID is a property of the object GroupInfo. Please see our API reference for more information.

Best regards,
Boris Pocatko

User avatar
Kentico Consulting
Kentico Consulting
kentico_borisp - 6/11/2010 7:32:35 AM
   
RE:Question about attachements
Hello,

You can find an example in the following file:

~CMSModules\Content\Controls\Attachments\FileUpload.ascx.cs

Best regards,
Boris Pocatko