This is a migrated thread and some comments may be shown as answers.

Quick Filter Q

1 Answer 34 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
sitefinitysteve
Top achievements
Rank 2
Veteran
sitefinitysteve asked on 14 Feb 2011, 06:07 PM
Hey,
  My report has a SqlDataSource pointing at a View, and the detail area has a bunch of tables on it, which are each individually bound to that datasource.

Question is I need to filter the data based on a GUID in all of these tables...so in the filter section I do Fields.formid = Parameters.FormID but the results end up empty.  If I try and do Fields.formid LIKE Parameters.FormID (dunno, figured it might be casing)..it fails on GUID to string conversion or something.

Can I filter the DS directly on that Parameter somehow perhaps?

1 Answer, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 16 Feb 2011, 10:00 AM
Hello Steve,

The Report Parameters Type property is used to give the report engine guidance which editor (UI) to render for the specified parameter. You can easily convert the input and output values to any type with an embedded Functions and an User Function such as the following one:

Copy Code
public static Guid ConvertToGUID(object guid)
{
    return new Guid(guid.ToString());
}

To display the GUID values in the Report Parameter UI you have to convert the Guid to String for the ReportParameter.AvailableValues.DisplayMember and ValueMember properties. You can use the CStr(System.Object) function that converts an expression to string value.

All the best,
Peter
the Telerik team
Get started with Telerik Reporting with numerous videos and detailed documentation.
Tags
General Discussions
Asked by
sitefinitysteve
Top achievements
Rank 2
Veteran
Answers by
Peter
Telerik team
Share this question
or