I am developing a Report using ReportViewer with ASP.NET and C#.
I'm binding data from a DataSource to a Tablix object using the .RDLC design view.
Inside this Tablix, there's a field that must me filled with one field from de datasource OR another one depending of an expression.
The expression in the field I am trying to use to achieve that is:
=IIf(IsNothing(Fields!PREMIO_CALCULADO_1.Value), Fields!PREMIO_CALCULADO_1.Value,Fields!RECUPERACAO_CALCULADA_INI_1.Value)
If the Field "PREMIO_CALCULADO_1" is null, then fill it with "RECUPERACAO_CALCULADA_INI".
I'm not having compilation errors but when I execute the report where this value should be there is an #error tag.
Am I doing something wrong with that expression?
Thank you very much.
It looks like you have the return values in the wrong position.
Just add a NOT before IsNothing.
Related
I want to add a dynamic hyperlink on click (action) on client Name with hyperlink expression value of url i.e. Dataset field. Dataset is retrieving the data but Fields!.url.Value doesn't retrieve value also field is not clickable. That means i am using wrong syntax. I have inserted static link and it's working.
Any help will be appreciable Thanks.
This is the report, i am retrieving it's data from data set
This the dataset that contains the url field
this the expression i want to set
I need to show parameters values inside table of rdlc report. When I put static text it is showing but parameter's values showed empty.
I need to show data in below format which can b easily done using table.
You can show report parameters using this syntax:
=Parameters!YourParameterName.Value
I am using Telerik Winforms Gridview and the Column expression.
I am trying to return data from a field (column) in a gridview using a IIF statement.
The below works:
IIF(customer_name='Bills Hairy Mess','win','lose')
The below crashes the form:
IIF(customer_name='Bills Hairy Mess',cust_ref_1_BOL,'lose')
I also tried
IIF(customer_name='Bills Hairy Mess',[cust_ref_1_BOL],'lose')
cust_ref_1_BOL is a valid field name and is pickable from within the expression editor under 'fields'
Is the above possible?
Turns out you can, fairly easy.
You do need to make sure that the field is in the columns list for the grid, which is what I was doing wrong.
It can be not visible, but needs to be there (obviously).
I had a need to exclude some columns from a export but still use them on the screen for calculations, this works fine by setting their visibility to false right before exporting.
I have a report in which I want to pass the parameters using a stored procedure. Now I have certain variables in which the value is static. I want to pass those values as the parameters into the Telerik report. e.g I have a DropDownList in which I have three values Sales Person, Customer and Product. Now I want to pass the selected index as a parameter to the telerik report designer. As I am new to this I do not know that what values I should pass in the designer and what values I have to pass pro-grammatically. I have designed the report but when set the value of parameter = new Report Parameter it gives me error that object reference not set to the instance if the object. Can anyone please help me.
I am using Telerik report designer inside the visual studio and Telerik report viewer for displaying the report.
http://blogs.telerik.com/telerikreportingteam/posts/09-03-14/telerik-reporting-connecting-to-stored-procedures.aspx
I have followed this link but it is OBSOLETE now.
http://www.telerik.com/help/reporting/how-to-sqldatasource-sct-storedprocedure.html
and while following the other link I get confused at the 10th point.
I have an existing DataGridView that is filled with data. I have a column in the DataGridView called "SignalStrength" and I wish to plot that data on a Chart control.
I figure the easiest way to do this is simply to bind the data but I cannot figure out the correct syntax. I want to do something like this:
Chart1.Series[0].Points.DataBindY(DataGridView1, "SignalStrength");
This does not compile because I'm not passing the correct type to the DataBindY function. It wants an IEnumerable type. What is the correct way to do this? I'd hate to have to iterate over my entire DataGridView to add the points.
Figured it out.
Chart1.Series[0].Points.DataBindY((DataView)DataGridView1.DataSource, "SignalStength");