I am using Crystal Reports in my web application and it is being loaded dynamically; i.e. it shows only those columns whose entire row is not null. The value of the parameters will be set at runtime.
Eventually the design of the report will be something as follows
param1 param2 param 3 param4
@formula1 @formula2 @formula3 @forumula4
where param1,param2,...
are parameters which shows the column headers and @formula1,@formula2,@formula3
are formula fields which show the detailfields.
The details of @formula1 is as follows
if {?param1}="EventName" Then {dtHealth.EventName}
Else If {?param1}="Location" Then {dtHealth.Location}
Else if {?param1}="CashsafeSerialNo" Then {dtHealth.CashsafeSerialNo}
Here there is a possibility that the param1
could be EventName
or Location
. I want to set the width of the formula field in crystalreport at runtime; i.e.
if param1="EventName"
@formula1.width=100px;
else if param1="Location"
@formula1.width=200px
Any help will be appreciated.
auto width to true
to the control in which you will bind that parameter. – RahulCanGrow
is different andAutoWidth
is different.But please tell me why you need this. – Rahul