The IF else statement of the formula field in the crystal report cannot be executed normally.

Source: Internet
Author: User

The formula fields are as follows:

If {maintable. botherdoc} = "on" then
Chrw (254)
Else
Chrw (168)

 

Maintable. botherdoc is a string value obtained from the check box through fromconnection. It is "on" When selected, and null when not selected.

The preceding formula field can be executed normally only when the value is on, that is, else will never be executed.

 

Other environments:

The crystal report adopts the push method, and the skeleton uses the dataset delegation. XSD. Only one table is maintable.

 

Solution:

If you change the default value of the maintable. botherdoc field in XSD to "" or other non-null or non-"on" strings, the above formula field works properly.

Note: The default value of the maintable. botherdoc field is changed to <dbnull>

 

That is to say, the default <dbnull> value is all used in this case !!!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.