changing text field value on runtime
hi group,
i have a problem that didn't show up on any sample files or in two books i bought (crystal reports for dummies and wrox - professional crystal reports for vs.net).
my users can specify the date range of the report on a web-form by filling start and end date into two textboxes before the dataset behind the report is filled.
in no example to reports ever show the exact date range selected in the report header. it's always like '... 2001' but what if users specified 10/23/02 to 11/15/02? how do i show the selected dates in the report header?
thanks if anyone can help me with it.
chris
Thus, passing parameters?
It seems as if yours is a matter of passing parameters to Crystal Report.
If this is the case, then look at what Babu, iamgautham and dinesh123 wrote:
from:
http://www.codeguru.com/forum/showth...ameter+crystal
Quote:
There is a formula editor in the Crystal report where u can build the formula.
U can pass the formula from the code to Crystal report SelectionFormula parameter.
Eg:
CrystalReport1.SelectionFormula =" {dept.EMPLOYEE ID} = {employee.EMPLOYEE ID}"
U can get more help from the Cystal report help.
from:
http://www.codeguru.com/forum/showth...ameter+crystal
Quote:
using automation server(cpeaut32.dll)
after creating application, report objects etc..
Private mobjcrpParam As CRPEAuto.ParameterFieldDefinition
Private mobjcrpParams As CRPEAuto.ParameterFieldDefinitions
Set mobjcrpParams = mobjcrpRep.ParameterFields
'' where mobjcrpRep is the report object
mobjcrpRep.ParameterPromptingEnabled = False
'' to prompt the parameter window or not
Set mobjcrpParam = mobjcrpParams.Item(1)
Dim paramValue As String
paramValue ="HELLO"
mobjcrpParam.SetCurrentValue paramValue
from:
http://www.codeguru.com/forum/showth...0&pagenumber=1
Quote:
Re: Crystal Report
hi,
That formulas(0) value is incorrect.
First, you have to create formula in crystal report design time.
assume "myVar" is your formula variable
Then you pass the value to that variable like
CrptHistory.Formulas(0) = "myVar = 'Hello'"
yours,
Babu
'------------------------------------------------
Re: Many Problems in Crystal Reports
hi,
for example you want to print name = 'Raj'
' you should enter the single quote for string data type
cr.SelectionFormula = "{Employee.Name} = 'Raj'"
'you no need to enter single quote for numeric data type.
cr.SelectionFormula = "{Employee.RecNo} = 10001"
do your level best.
Babu
crystal reports changing text field value on runtime
hi group,
i moved the thread from another vb forum where i posted it by accident.
'-----
[Cimperiali note: the thread is now listed above]
'----
i'm looking for a way to transfer a string into the report header of a crystal report. i'm working with vb.net enterprise architect standard installation (with other lanugages not installed).
just learned that there is something called craxdrt9.dll to be installed. is this only for vb6 or also for .net? i couldn't find it on my harddrive.
any help appreciated a lot, bought two books but it was never mentioned.
chris