Report Design
 Crystal Reports Forum : Crystal Reports for Visual Studio 2005 and Newer : Report Design
Message Icon Topic: greate problem Post Reply Post New Topic
Author Message
hosam
Newbie
Newbie


Joined: 20 May 2007
Location: Egypt
Online Status: Offline
Posts: 3
Quote hosam Replybullet Topic: greate problem
    Posted: 22 May 2007 at 11:16pm

hi all

i've a great problem that can't be solved until now by crystal report

i'm creating a control program for exam results

the table of the result is created dynamically by code

the table name i don't know

ex  the table created like this

      courseResult_facName_deptName_Year

so i don't know the facName , deptName and year

so i can not specify a table source for the dataset

 

i hope you understand me

 2- the colmns in this dynamic table that generated by code i don't know too these colmns names

i want u to solve me this problem by creating a dynamic crystal report for this table and colmns in this table

IP IP Logged
andyoneill
Newbie
Newbie


Joined: 19 May 2007
Online Status: Offline
Posts: 12
Quote andyoneill Replybullet Posted: 18 Jun 2007 at 4:22am
But presumably you can change the code which builds the dataset on the fly.
 
Base your reportsource on a datatable.
Use sql to alias the field names if they can change.
Build your string up on the fly.
something like:
 
Select
 variablefieldname1 as v1,
 variablefieldname2 as v2
from whatevertable
 
Your report sees variables v1 and v2.
 
You can specify the datatable name in design or change the property using the code I posted a couple of days ago.
 
Your report must end up being presented a datasource with the same datatable name and same field names and types as the dataset you build against.
You can generate the dataset using the usual dataset designer in vs2005 or build a view even.  Either way you do of course need a database at design time.
 
BTW
I say datatable rather than dataset because they use less resource. 


Edited by andyoneill - 18 Jun 2007 at 4:25am
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.031 seconds.