• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 230
  • Last Modified:

Dynamically change Text on CRytal reports in asp .net 2.0

I have server 2003 a
aap .net 2.0
Crytal reports developer XI
mysql backend

I need to know how to do is dynamically change a text box on the report from the Aspx.vb code and also do I have to recreate my report everytime I change the data connection?  Both of these questions seem simple enough but I can't find a resource to answer them.

Jan Mishkin
Jan Mishkin
  • 3
  • 2
2 Solutions
Jai STech ArchCommented:
you dont need to recreate the report !!!
you can set the connection string as a parameter to your crystal report viewer and the CR will take this server name and db name as the data source along with your query....

and you can have an expression (a formula) which will display a paramter value(@something)...you can have this value being passed from your front end (usual way of setting formalas fron Asp.net)
Jan MishkinIT ManagerAuthor Commented:
jaiganeshsrinivasan: I don't mean reconnecting to the same data set. I mean - say a I want to have a new report based on a different view with some different fields but I don't want to recreate the full report i.e I want to keep the entire formatt of the report but just reasign and add a few new fields. It seems like it forces me to clear all my field boxs.

mimcc: I will make time to view those pages and then accept solution('s)
Cloud Class® Course: MCSA MCSE Windows Server 2012

This course teaches how to install and configure Windows Server 2012 R2.  It is the first step on your path to becoming a Microsoft Certified Solutions Expert (MCSE).

Unfortunately that is the way Crystal works.  It uses a positional rather than field name to track the fields on the report.

You can try setting the data source inside the report but to do what you want from code probably isnt't possible.

Jan MishkinIT ManagerAuthor Commented:
In terms of recreating the full report everytime I change the structure to the underlying table - I think this is nuts  and I'm assuming that I'm doing something wrong because I can't believe that the CR would be set up like this. Am I right?
Jan MishkinIT ManagerAuthor Commented:
OK - I don't think I clearly stated the 2cnd problem

When using xsd as a source when the xsd structure changes how do I update the CR report

her3e is the answer
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.

Join & Write a Comment

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now