Monday, October 26, 2015

Crystal Reports : Using (all) in the Selection Criteria

Let us consider our {?UserID} parameter, which accepts multiple values.
Let us further consider that the end-user will need to occasionally print the report for all UserID's. They could simply add each UserID to the parameter before printing the report, but in cases of many UserID's, this becomes cumbersome.
A better solution is to give an "all" option in the parameter choices, then use the following code:

if {?UserID} not like "*(all)*" then {SALES.USERID} = {?UserID} else true

Here is what's happening:
IF our parameter DOES NOT have he word "all" within it, we execute the Selection Criteria normally. The trick here is that our ELSE clause ends in TRUE, which means that we "skip over" this part of the Selection Criteria, therefore returning ALL UserID's.

3 comments:

PLC training in chennai said...

WIZTECH Automation, Anna Nagar, Chennai, has earned reputation offering the best automation training in Chennai in the field of industrial automation. Flexible timings, hands-on-experience, 100% practical. The candidates are given enhanced job oriented practical training in all major brands of PLCs (AB, Keyence, ABB, GE-FANUC, OMRON, DELTA, SIEMENS, MITSUBISHI, SCHNEIDER, and MESSUNG)

PLC training in chennai
Automation training in chennai
Best plc training in chennai
PLC SCADA training in chennai
Process automation training in chennai
Final year eee projects in chennai
VLSI training in chennai

Zheng junxai5 said...

zhengjx20160623
coach outlet store online
louis vuitton handbags
christian louboutin sale
jordan retro 13
air jordan shoes
christian louboutin outlet
burberry handbags
louis vuitton outlet
jordan retro 11
ralph lauren
kd 7 shoes
michael kors outlet clearance
coach outlet
toms outlet
ray bans
louis vuitton bags
polo ralph lauren
giuseppe zanotti outlet
supra for sale
nike store
louis vuitton outlet
jordan 3 powder blue
michael kors outlet
gucci bags
nike air max uk
toms outlet
ray ban sunglasses outlet
louis vuitton outlet
vans sneakers
michael kors outlet
polo ralph lauren outlet
louis vuitton bags
designer handbags
coach outlet store online
nike running shoes for men
celine bags
louis vuitton purses
ray ban sunglasses
coach outlet
michael kors handbags

Meiqing Xu said...

polo ralph lauren outlet online
converse shoes
louboutin uk
birkenstock sandals
true religion jeans
converse outlet
moncler outlet
ugg boots
michael kors outlet store
coach outlet
20161209caiyan