Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Nulls in repository 1

Status
Not open for further replies.

lyanch

Programmer
Feb 12, 2002
1,048
US
How does anyone handle null checking in custom functions? My functions don't return anything if any of the arguments are null. I would prefer to do the checking withing the custom function in the repository but "isnull" isn't allowed in custom functions?

How can I check for null? especially since null *means* something for many of the formulas and I can't just replace it with something else to pass to the formula.

if isnull(x) then "not set"
else totext(x)

where x is a number that can essentially be any value (positive, 0 and negative) so i can't "set" it to a value to send to a formula.

Thanks in advance,

Lisa



 
Assuming Crystal 8.5, try
Code:
if not isnull ({your.field}) then ...

Madawc Williams
East Anglia, Great Britain
 
In the crystal 9 repository. "Isnull is not a valid function"

Lisa
 
Just got done speaking with customer support. Custom formulas cannot handle nulls and will return null if any of the input variables are null. Kind of negates the use of the respository where nulls are as valid of a value as anything else.

Bummer dude

Oh.. I had read earlier that the repository was excluded in 10. Customer support said that it would still be included.




Lisa
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top