Trying to use an already present sqldatasource for a local VS.NET crystal report

VB/ASP.NET 2.0: I already have a sqldatasource which calles a stored proc that accepts control parameters for a filtered search. The results are displayed in a gridview. I want these same results displayed in a LOCAL crystal report (the CR that's intergrated within VS.NET) instead of the gridview. How do I bind this same existing sqldatasource to a local crystal report? I'd like to have this binding in a button click and also pdf exporting in a different button.
techpr0Asked:
Who is Participating?
 
techpr0Author Commented:
sqldatasource doesn't appear anywhere in the article. Plus, I know it would have worked if I "COuld you create the dataset then bind it" but that was why I submitted this post to find out how to do it. I did figure out how to convert a sqldatasource into a dataset but it wasn't mentioned in your article:

DataView view = (DataView)SqlDataSource1.Select(DataSourceSelectArguments.Empty);

DataTable table = view.ToTable();
DataSet ds = new DataSet();
ds.Tables.Add(table);

But I ended up not doing it this way. I ended up doing it like this: http://www.codeproject.com/KB/cs/VMCrystalReports.aspx?msg=3007117#xx3007117xx 
Worked perfect! I didn't even have to use a dataset. Thanks any way mlmcc.
0
 
techpr0Author Commented:
Ok, I was able to connect my SQLDataSource to my CrystalReportSource and then my CrystalReportViewer to my CrystalReportSource which I discovered I orginally was doing correctly but thought I wasn't because I couldn't find the data the SQLDataSource returns in my report within the Server Explorer nor with the Database Expert. I found it here: http://msdn.microsoft.com/en-us/library/ms227820(VS.80).aspx . Now my problem is accessing the data from my SQLDataSource from the Server Explorer to build my report. Can you please show me how to find this???
0
 
mlmccCommented:
Check this method of feeding your report from the application

http://www.emoreau.com/Entries/Articles/2006/09/Feeding-Crystal-Reports-from-your-application.aspx

mlmcc
0
 
techpr0Author Commented:
Thanks for your effort mlmcc but... I've only read half of it but it appears this article is about binding a crystal report to a dataset; I'm looking to bind my report to a asp.net/vb.net 2.0 SqlDataSource. Any more suggestions?
0
 
mlmccCommented:
It is about that.  COuld you create the dataset then bind it.

mlmcc
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.