logo

Warning: The forum is now for consultation only. Please use GitHub Discussions to post any questions or comments.


Welcome Guest ! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
Padma  
#1 Posted : Tuesday, October 29, 2019 7:07:58 PM(UTC)
Padma

Rank: Member

Groups: Registered
Joined: 10/21/2019(UTC)
Posts: 16
United States

I have a data table in the report - I need to have a header that displays a title and selected restriction value.

In another report - I was able to do this for chart title by modifying the code. But I do not see how to implement this for the data table - Any suggestions would be helpful..thanks
epf  
#2 Posted : Wednesday, October 30, 2019 4:03:22 PM(UTC)
epf

Rank: Administration

Groups: Administrators
Joined: 12/20/2013(UTC)
Posts: 1,209
Switzerland

Thanks: 14 times
Was thanked: 206 time(s) in 199 post(s)
There are several ways to do that, I would suggest the following:
- Select your 'Model Container' view, and add a 'Free View'
- Move the new view before your 'Page Table' View
- Edit the template of your view and put code like this:

Code:
@using Seal.Model
@using Seal.Helpers
@{
    Report report = Model;
    ReportView view = report.CurrentView;
    ReportView modelView = report.CurrentModelView;
    ReportModel reportModel = modelView.Model;
    ResultPage page = report.CurrentPage;
}

<h3>@reportModel.GetRestrictionByName("Customer").Value1</h3>


This will add a header based on the restriction value enter by the user.
Check also https://sealreport.org/R...es#lineDynamicChartTitle
Padma  
#3 Posted : Wednesday, October 30, 2019 6:32:35 PM(UTC)
Padma

Rank: Member

Groups: Registered
Joined: 10/21/2019(UTC)
Posts: 16
United States

Thank you. That worked perfectly!
Users browsing this topic
Guest (3)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.