Print Page | Close Window

ReportControl FieldChooser and C#

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Suite Pro
Forum Description: Topics Related to Codejock Suite Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=1608
Printed Date: 29 April 2024 at 8:30am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: ReportControl FieldChooser and C#
Posted By: Boyd
Subject: ReportControl FieldChooser and C#
Date Posted: 30 December 2004 at 10:47am

I'm trying to use ReportControl in Visual C# .NET 2003.  I have ReportControl on one form and have a second form with the FieldChooser on it (just like the VB Sample App).  In order to tie to two together, you have to set the 'ReportControl.FieldChooser' property to reference the FieldChooser control on the 2nd form.

The 'ReportControl.FieldChooser' property expects an object of type 'XtremeReportControl.FieldChooser'.  When I try to cast the 'FieldChooser' object reference on my form to this type, I get an 'InvalidCastException' saying that the specified cast is not valid.

Can someone help explain how I use FieldChooser with ReportControl in Visual C# .NET 2003?

Thanks in advance!




Replies:
Posted By: Boyd
Date Posted: 12 January 2005 at 8:00am

For anyone interested, the following code can be adapted to set the FieldChooser for a ReportControl:

axReportControl.FieldChooser = axFieldChooser.GetOcx() as XtremeReportControl.FieldChooser;




Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net