Showing posts with label names. Show all posts
Showing posts with label names. Show all posts

Thursday, March 22, 2012

custom styles usage

I am amazed that we cannot use our own styles?. There is only a predefined set of styles in HTMViewer.css to which we cannot add our own style names and use it for a textbox?

Has anyone done this?

Thanks

Using Custom Style Sheet in SQL Reporting Services 2000

Changing the style-sheet in SQL Reporting Services is one question that I have seen commonly asked in the forums. Well yes the answer is straight forward but at times some straight answers don’t work :) .

Following is my finding on how to use your own style sheet in Reporting Services:

Prerequisite : SP2 hot fix: http://support.microsoft.com/default.aspx?scid=kb;en-us;901383

Following are the steps for using custom style sheet in Reporting Services:

1. Add <HTMLViewerStyleSheet> element in RSReportServer.config within the <configuration> element.
2. DON’T include the ".css" extension in the name of the style sheet.
3. Example: <HTMLViewerStyleSheet>htmlviewer2</HTMLViewerStyleSheet>

Following is going to fail:
<HTMLViewerStyleSheet>htmlviewer2.css</HTMLViewerStyleSheet>

Following works:
<HTMLViewerStyleSheet>htmlviewer2</HTMLViewerStyleSheet>

Make sure that the style sheet is located in the styles directory of Reporting Services (i.e. C:\Program Files\Microsoft SQL Server\MSSQL\Reporting Services\ReportServer\Styles).

The default style sheet used by the HTML Viewer uses the font Verdana for displaying labels and dropdown values. Unfortunately, Verdana does not have full Unicode support.
SP2 (with the hot fix at http://support.microsoft.com/default.aspx?scid=kb;en-us;901383) allows you to change the stylesheet that is used by the viewer.

If you want to hide items on the Reporting Services Toolbar, you can do this by customizing each button/item individually by changing the stylesheet. Basically, you just need to change the style display:inline to display:none for the items which you don't want to show/hide on the toolbar.

Hope this should help some of you in using a custom style sheet in Reporting Services.

http://blogs.msdn.com/ketaanhs/default.aspx

Sunday, March 11, 2012

Custom names for summary fields

Using Crystal Reports 8.5 I have created a report which displays a pie chart of the column totals in a report. Unfortunately the names of the summary fields are used as labels for the pie chart slices and they are ugly - things like "sum qryOrders.OrderValue". Is there a way to replace these labels with my own choice of text?From the deafening silence, the answer appears to be 'No'. In case anyone else has the same issue, here is a workaround. Suppress the display of pie slice labels. Suppress the display of the chart legend. Create your own legend box using the basic drawing tools - filled rectangles - and add your own text labels.|||For the sake of future Googlers; I too was having this problem, and I had given up when I realized that if you sort "in specified order", you can then set up your "Named Groups" such that the "Group Name" is the name that you wish to have displayed.

For example, the formula for one of my named groups is "@.Allocation" "is equal to" "International Equity", and the name of the group is "Int'l Equity".

Works like a charm, sorry I'm too late to help you.|||Well, within a couple of minutes of posting, I realized that this only works if you have only one field to show a value for. So, it's not going to work where I really need it to, but still, it's useful elsewhere.

Friday, February 24, 2012

Custom columns names for custom reports?

Our application allows the customer to change the on-screen field names to his personal requirements (eg Target = 2008 Target). My customer wants his on-screen field names to be reflected the metadata view so he can write reports with his change field names. We have several customers with this application so the field names will change by customer.

How do you do this, can SQL/Server support 2 field names - the original and a preferred display option?

If we change the field names how do we ensure that existing (or future) reports from Reporting Services dynamically pick up the customers preferred field name and any existing (or inherited) reports will continue always run.Question moved to SQL Server Forum.

Friday, February 17, 2012

Custom Assembly error

I have created a custom assembly to automatically display parameter names in
a textbox an a report. The parameters display through the previ
When I run my report through 'DebugLocal' mode.
it breaks here:
Public Class ParameterList
Public Shared Function GetParameterNames()
Dim rs As New ReportingService
rs.Credentials = System.Net.CredentialCache.DefaultCredentials
Dim report As String = "/Commission Reports/Detailed Broker
Commission Bordereaux"
Dim forRendering As Boolean = False
Dim historyID As String = Nothing
Dim values As ParameterValue() = Nothing
Dim credentials As DataSourceCredentials() = Nothing
Dim strParam As String = ""
Dim Parameters() As ReportParameter
Parameters = rs.GetReportParameters(report, historyID, forRendering,
values, credentials)
If Not (Parameters Is Nothing) Then
Dim rp As ReportParameter
For Each rp In Parameters
strParam = rp.Prompt & strParam
Next rp
End If
Return strParam
End Function
End Class
break point : rs.Credentials = System.Net.CredentialCache.DefaultCredentials
The message reads :
"Request for the permission of type
'System.Security.Permissions.EnvironmentPermission,
mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
failed."
What can I do?
Any help would be appreciated.
ThanksOn Jun 29, 3:28 am, DylCole <DylC...@.discussions.microsoft.com> wrote:
> I have created a custom assembly to automatically display parameter names in
> a textbox an a report. The parameters display through the previ
> When I run my report through 'DebugLocal' mode.
> it breaks here:
> Public Class ParameterList
> Public Shared Function GetParameterNames()
> Dim rs As New ReportingService
> rs.Credentials = System.Net.CredentialCache.DefaultCredentials
> Dim report As String = "/Commission Reports/Detailed Broker
> Commission Bordereaux"
> Dim forRendering As Boolean = False
> Dim historyID As String = Nothing
> Dim values As ParameterValue() = Nothing
> Dim credentials As DataSourceCredentials() = Nothing
> Dim strParam As String = ""
> Dim Parameters() As ReportParameter
> Parameters = rs.GetReportParameters(report, historyID, forRendering,
> values, credentials)
> If Not (Parameters Is Nothing) Then
> Dim rp As ReportParameter
> For Each rp In Parameters
> strParam = rp.Prompt & strParam
> Next rp
> End If
> Return strParam
> End Function
> End Class
> break point : rs.Credentials = System.Net.CredentialCache.DefaultCredentials
> The message reads :
> "Request for the permission of type
> 'System.Security.Permissions.EnvironmentPermission,
> mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
> failed."
> What can I do?
> Any help would be appreciated.
> Thanks
This link might be helpful.
http://odetocode.com/Articles/216.aspx
Regards,
Enrique Martinez
Sr. Software Consultant|||"EMartinez" wrote:
> On Jun 29, 3:28 am, DylCole <DylC...@.discussions.microsoft.com> wrote:
> > I have created a custom assembly to automatically display parameter names in
> > a textbox an a report. The parameters display through the previ
> >
> > When I run my report through 'DebugLocal' mode.
> > it breaks here:
> >
> > Public Class ParameterList
> >
> > Public Shared Function GetParameterNames()
> > Dim rs As New ReportingService
> > rs.Credentials = System.Net.CredentialCache.DefaultCredentials
> > Dim report As String = "/Commission Reports/Detailed Broker
> > Commission Bordereaux"
> > Dim forRendering As Boolean = False
> > Dim historyID As String = Nothing
> > Dim values As ParameterValue() = Nothing
> > Dim credentials As DataSourceCredentials() = Nothing
> > Dim strParam As String = ""
> >
> > Dim Parameters() As ReportParameter
> > Parameters = rs.GetReportParameters(report, historyID, forRendering,
> > values, credentials)
> >
> > If Not (Parameters Is Nothing) Then
> > Dim rp As ReportParameter
> > For Each rp In Parameters
> > strParam = rp.Prompt & strParam
> > Next rp
> > End If
> > Return strParam
> > End Function
> >
> > End Class
> >
> > break point : rs.Credentials = System.Net.CredentialCache.DefaultCredentials
> >
> > The message reads :
> >
> > "Request for the permission of type
> > 'System.Security.Permissions.EnvironmentPermission,
> > mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
> > failed."
> >
> > What can I do?
> >
> > Any help would be appreciated.
> >
> > Thanks
>
> This link might be helpful.
> http://odetocode.com/Articles/216.aspx
> Regards,
> Enrique Martinez
> Sr. Software Consultant
> Thanks Enrique,
This helped (on my machine). However, when I try and put my assembly on
another machine, it doesnt work. Do you have another way to display the
parameter names on a report? if not I will figure it out eventually.
Thanks again