Jump to content
We've recently updated our Privacy Statement, available here ×

XLS Formula with quotation marks


zaya80

Recommended Posts

 HI all,

I'm using iReport 3.5.2.

I would like to count in my report all empty cells in a column. TheFormula in excel is COUNTIF(B8:B500;"")

Due to the special sign " (quotation mark) i have to escape the sign with \. (COUNTIF(B8:B500;\"\"))

But this Formula doesn't yield any result on the export sheet. (see the code mentioned below)

Has anyone an idea how could i write this formula in iReport?

 

Thanks, 

Zaya

 

 

 

 

Code:
<reportElement key="staticText-31" mode="Transparent" x="176" y="90" width="257"    height="15"><propertyExpression name="net.sf.jasperreports.export.xls.formula"><![CDATA["COUNTIF(B8:B500;\"\")"]]></propertyExpression></reportElement>				
Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

jasper report has its own formulas ( $F{EmptyColmn} ==""? $V{CountRow}:" " )

 

this will give you empty record with in given column. In Excel check your excel report, if it is not showing merging cell error.

 

 

Regards

Hasham

Link to comment
Share on other sites

Dear Hasham

Thank you for your response. But it doesn't still work. (Or i hadn't understood your answer :-( )

In the TextField i was giving this formula: ( $F{QUANTITY}==""? $V{CountRow}:" ")

($F{QUANTITY} is the column in the Detail Band,in which i searching for empty fields

$V{CountRow} is a variable, which has following properties:  Calculation: Count
                                                                                                               Increment type: Column
                                                                                                               Reset Type: Report
                                                                                                                Variable Class: java.lang.String)

I hope, you understand my horrible english.

 

Regards,

Zaya

 

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...