{"id":932,"date":"2008-07-08T00:36:22","date_gmt":"2008-07-08T07:36:22","guid":{"rendered":"http:\/\/members.crystalreportsbook.com\/books\/?p=932"},"modified":"2008-07-08T00:36:22","modified_gmt":"2008-07-08T07:36:22","slug":"2014-changing-the-record-selection-filter","status":"publish","type":"post","link":"http:\/\/www.crystalreportsonlinetraining.com\/training\/2014-changing-the-record-selection-filter\/","title":{"rendered":"20.14 Changing the Record Selection Filter"},"content":{"rendered":"<h2>Changing the Record Selection Filter<\/h2>\n<p>The record selection filter tells Crystal Reports which records you want to include in the report&#8217;s output. Any records not matching the the record selection filter are excluded. The RAS lets you change the filter with a single statement: RecordFilterController.SetFormulaText(). To change the grouping formula, use the GroupFilterController.SetFormulaText() method. The next two listings demonstrate this.<\/p>\n<p>         <b>Listing 20-11. Changing the record selection formula.<\/b><br \/>\n         <b>[VB.NET]<\/b><br \/>\n         <code>Private Sub ModifyFilter(ByVal NewFilter As String, ByVal rcd As ISCDReportClientDocument)<\/code><br \/>\n         <code>rcd.DataDefController.RecordFilterController.SetFormulaText(NewFilter)<\/code><br \/>\n         <code>End Sub<\/code><br \/>\n         <b>[C#]<\/b><br \/>\n         <code>private void ModifyRecordFilter(string NewFilter, ISCDReportClientDocument rcd)<\/code><br \/>\n         <code>{<\/code><br \/>\n         <code>rcd.DataDefController.RecordFilterController.SetFormulaText(NewFilter);<\/code><br \/>\n         <code>}<\/code><br \/>\n         <b>Listing 20-12. Change the group selection formula.<\/b><br \/>\n         <b>[VB.NET]<\/b><br \/>\n         <code>Private Sub ModifyFilter(ByVal NewFilter As String, ByVal rcd As ISCDReportClientDocument)<\/code><br \/>\n         <code>rcd.DataDefController.GroupFilterController.SetFormulaText(NewFilter)<\/code><br \/>\n         <code>End Sub<\/code><br \/>\n         <b>[C#]<\/b><br \/>\n         <code>private void ModifyGroupFilter(string NewFilter, ISCDReportClientDocument rcd)<\/code><br \/>\n         <code>{<\/code><br \/>\n         <code>rcd.DataDefController.RecordFilterController.SetFormulaText(NewFilter);<\/code><br \/>\n         <code>}<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Changing the Record Selection Filter The record selection filter tells Crystal Reports which records you want to include in the report&#8217;s output. Any records not matching the the record selection filter are excluded. The RAS lets you change the filter with a single statement: RecordFilterController.SetFormulaText(). To change the grouping formula, use the GroupFilterController.SetFormulaText() method. The [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[47,40],"tags":[],"class_list":["post-932","post","type-post","status-publish","format-standard","hentry","category-chapter-20-dynamic-report-modification","category-crystal-reportsnet-2008","entry"],"_links":{"self":[{"href":"http:\/\/www.crystalreportsonlinetraining.com\/training\/wp-json\/wp\/v2\/posts\/932","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.crystalreportsonlinetraining.com\/training\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.crystalreportsonlinetraining.com\/training\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.crystalreportsonlinetraining.com\/training\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.crystalreportsonlinetraining.com\/training\/wp-json\/wp\/v2\/comments?post=932"}],"version-history":[{"count":0,"href":"http:\/\/www.crystalreportsonlinetraining.com\/training\/wp-json\/wp\/v2\/posts\/932\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.crystalreportsonlinetraining.com\/training\/wp-json\/wp\/v2\/media?parent=932"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.crystalreportsonlinetraining.com\/training\/wp-json\/wp\/v2\/categories?post=932"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.crystalreportsonlinetraining.com\/training\/wp-json\/wp\/v2\/tags?post=932"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}