<
add
name
=
"TargetZeroEntities"
connectionString
=
"metadata=res://*/TargetZero.csdl|res://*/TargetZero.ssdl|res://*/TargetZero.msl;provider=System.Data.SqlClient;provider connection string="data source=uldev02\sql2008;initial catalog=TargetZero;persist security info=True;user id=TargetZeroDev;password=TargetZeroDev1@;MultipleActiveResultSets=True;App=EntityFramework""
providerName
=
"System.Data.EntityClient"
/><
br
>
<
add
name
=
"TargetZeroReportEntities"
connectionString
=
"metadata=res://*/ReportingContext.csdl|res://*/ReportingContext.ssdl|res://*/ReportingContext.msl;provider=System.Data.SqlClient;provider connection string="data source=uldev02\sql2008;initial catalog=TargetZero;persist security info=True;user id=TargetZeroDev;password=TargetZeroDev1@;multipleactiveresultsets=True;application name=EntityFramework""
providerName
=
"System.Data.EntityClient"
/>
I have a crosstab that displays financials over three time periods (year, month, week) this is the first column group. The next sub column group is actual vs forecast. The aggregate column for this takes max(field.value) - min(field.value) to determine the variance between actual and forecast.
I need to figure out either how to conditionally format this field to show whether the variance is favorable or unfavorable (probably with color)
I need to write the expression to subtract
(fields.value Where fields.type = actual) - (fields.value Where fields.type = forecast)
with this the result would be negative if unfavorable.
Basically I need to create case or switch statements for conditional formatting and format string values can this be done either through the expression editor or through the backend C# code behind page.
I cannot get any of the following to work for me:
I have a WPF project that contains several Telerik Report Q3 2013 objects. The reports also have parameters and they preview just fine. During runtime, each report runs a query that fetches data from a SQL Server database and displays the results in the reports.
The WPF app has a menubar. At runtime, a user can go to the Reports menu, and choose to preview Report1, Report2, or Report3. There is a WPF window that hosts a report viewer control (called RptViewer). When the code behind a menu option executes, such as the Report3 menu option, the code basically does the following:
private void mnuReports_View_Report3_Click(object sender, RoutedEventArgs e) {
InstanceReportSource irSrc = new InstanceReportSource();
RptViewer winRptView = new RptViewer();
irSrc.ReportDocument = new Report3();
winRptView.rptViewer.ReportSource = irSrc;
winRptView.Show();
}
This all works fine and the correct report is previewed every time. My problem is that each report stores a static connection string.
I intend for some of my clients to install and use this WPF app within their own network. The reports will need to access the data within their own SQL Server databases. So I need the connection strings to be updated accordingly. We already have the correct connection strings; we just need the string to be assigned to a report whenever it is loaded by the report viewer. I don’t know why I can’t get this to work.