RDLC Report Defining Root Folder

RDLC Report Defining Root Folder

Tiffany_Hayden_
Collaborator Collaborator
1,236 Views
5 Replies
Message 1 of 6

RDLC Report Defining Root Folder

Tiffany_Hayden_
Collaborator
Collaborator

Hi 

 

I'm creating a custom report. I am trying to define my root folder as the selected folder the report is ran from. So if the user selects a folder and runs this report from there, the report sets the "Vault_SearchRoot" folder as the $\"FolderSelected". Do I have to use the Vault API to determine the folder selected? Just wandering on direction here. 

 

 

Reporting Vault Root Folder.PNG

 

Tiffany Hayden
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

0 Likes
Accepted solutions (1)
1,237 Views
5 Replies
Replies (5)
Message 2 of 6

Markus.Koechl
Autodesk
Autodesk

Vault report engine fills the parameter accordingly. So this is built-in functionality that does not require customization in your own templates as long as you use the default report commands from saved searches, search results or selected folders. More details on custom report editing and extensions can be found in the training package on AKN: https://knowledge.autodesk.com/community/article/196571 

In case you intend to write a custom report command using the API then you need to fill all parameters on your own. A sample code writing a custom report engine is available here: https://github.com/koechlm/Vault-Sample---Item-BOM-Report-Job.



Markus Koechl

Solutions Engineer PDM, Autodesk Central Europe
0 Likes
Message 3 of 6

Tiffany_Hayden_
Collaborator
Collaborator

I found your detailed explanation on the first link a few days ago and it got me to here. (And it is an amazing reference!) You mentioned you can use "Selected Folders" How do I put that in the expression in Visual Studio to make that happen? Do you have an example of that? Would it be Vault_SelectedFolders and add it under the Parameters? Something like that? I'm trying to make it to where the user doesn't have to be in the "Find" box and add the folder and search conditions or have a saved search. 

 

@Markus.Koechl 

Tiffany Hayden
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

0 Likes
Message 4 of 6

Markus.Koechl
Autodesk
Autodesk

The Vault command "Report..." is available in the Search Dialog, saved searches or Reports detail tab only. For each context, folder selection is available and passed to the report as a parameter (build-in).

So, I am not sure that I got your intent: are you about adding a custom command that should create a report, e.g. on selected files? I had a sample in earlier training material but removed it for the latest issue avoiding confusion about template customization for the standard Vault command "Report..." and creating custom extensions (custom commands) leveraging the report viewer API.

 



Markus Koechl

Solutions Engineer PDM, Autodesk Central Europe
0 Likes
Message 5 of 6

Tiffany_Hayden_
Collaborator
Collaborator

@Markus.Koechl 

 

Hi Markus, 

 

I'll explain further and see if that helps. 

I'd like to be able to 

 

Click on the folder. Then select the report that I wish to run. 

 

vault reports snip.png

 

vault reports snip2.png

 

vault reports snip3.png

 

Does this explain what I'm trying to do? Let me know! 

Thank you

Tiffany Hayden
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature

0 Likes
Message 6 of 6

Markus.Koechl
Autodesk
Autodesk
Accepted solution

Hi Tiffany, I apologize for my delayed response. You need to check templates, that have the Vault_FolderName parameter. All File*.rdlc templates have it. Folder_Parameter.png

Then you can select the folder -> select file table report -> and get the root folder that you selected in the header. So, in this case, it is not a search result and these parameters are empty.

SelectFolder-ContentReport.png



Markus Koechl

Solutions Engineer PDM, Autodesk Central Europe
0 Likes